Description
Use more efficient method to get Arduino CLI version
Describe the request
Employ a technique for obtaining the version of the bundled Arduino CLI that does not trigger the pointless update check.
🙂 The Help > About Arduino IDE menu item will be responsive.
Describe the current behavior
The Help > About Arduino IDE menu item opens a dialog which displays information about the Arduino IDE. This includes the version of the bundled copy of Arduino CLI.
The Arduino CLI version is obtained by running the following command:
arduino-cli version --format json
In addition to displaying the version, this command triggers a check for the availability of a newer version of Arduino CLI:
While that update check is useful to the users running the command directly, it is completely pointless for this application, both because the IDE does not even use the information about availability of an update and because the IDE is designed to use a specific version of Arduino CLI and updating the bundled Arduino CLI to a new version is strongly discouraged.
For unknown reasons (perhaps transient network conditions), this update check sometimes takes on the order of a few seconds to complete.
🙁 The dialog opening is blocked while waiting, which is a poor experience for the user who will frustrated that such a simple dialog should be so slow to open.
Arduino IDE version
2.0.1-snapshot-32d904c
Operating system
Windows
Operating system version
10
Additional context
The update check will not be done when a non-release version of Arduino CLI is bundled with the IDE, so make sure your IDE meets that condition if trying to reproduce the slow dialog opening.
The slow update check is intermittent. It does happen frequently though so you should be able to reproduce it within several cycles of opening and closing the dialog.
Previously discussed in passing at #1289 (comment)
Issue checklist
- I searched for previous requests in the issue tracker
- I verified the feature was still missing when using the latest nightly build
- My request contains all necessary details