Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

The board discovery might miss detecting detached board when the package index is being updated #1186

Open
Labels
topic: codeRelated to content of the project itself type: imperfectionPerceived defect in any part of project
@kittaakos

Description

Describe the problem

Originally from #1181:

There is a bug with #1167 that can be reproduced on my Windows machine with the following steps:

  • IDE2 is up and running, a board is connected and recognized by IDE2; it's the selected board,
  • Stop IDE2,
  • Start IDE2 (You can see the board is connected from the dropdown),
  • Disconnect the board when the Downloading .... notification message (this is when IDE2 initializes the core client),
  • Core client reinitialization is done, the board is not connected, but IDE2 still shows it as a connected board.

This PR fixes this issue, but IDE2 must stop the board discovery before re-initializing the core client and restarting after it. WheIDE2 stops the board discoveryE2 before the re-init; zero available board and ports must be broadcasted to the frontends. So users will see a disconnect/reconnect board before/after the index update and the core client re-init.

If the IDE2 misses the board detachment event, the boards selection dropdown will show the board as a connected one although it was detached. Attaching + detaching the board should solve this problem.

To reproduce

Note that the bug cannot be reproduced consistently.

Please reference the description of this issue.

Expected behavior

The detached board is tracked by the IDE2 during the indexes update/core client re-initialization.

Arduino IDE version

a003831

Operating system

macOS

Operating system version

12.3.1

Additional context

I could only reproduce the defect from my slow Windows env, running the IDE2 from the source.

Issue checklist

  • I searched for previous reports in the issue tracker
  • I verified the problem still occurs when using the latest nightly build
  • My report contains all necessary details

Metadata

Metadata

Assignees

No one assigned

    Labels

    topic: codeRelated to content of the project itself type: imperfectionPerceived defect in any part of project

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions

        AltStyle によって変換されたページ (->オリジナル) /