Description
Describe the request
To enhance the reliability of Arduino IDE extensions, IDE needs to ensure that the Arduino state updates are independent of the language server's availability.
As highlighted at dankeboy36/esp-exception-decoder#28 (comment), the compileSummary
of the ArduinoState
may be undefined
due to potential startup failures of the Arduino Language Server. This scenario can lead to issues for extensions developed for the Arduino IDE.
To mitigate this issue, I propose decoupling the ArduinoState
update process from the language server itself. Given that the compile summary is already accessible, IDE should modify the compile
command to resolve with a CompileSummary
rather than void
. Additionally, the compile command should be relaxed to resolve with undefined
when the data is partial.
Instead of relying on executed commands to monitor the compile summary, IDE will directly use the resolved compile value to update the state for extensions. Furthermore, the frontend will dispatch the notification that a build has occurred directly from the frontend to the VS Code extension. This should help provide data for extensions reliably and not change the existing IDE behavior.
Describe the current behavior
IDE backend directly executes the command to update the build path after a verify:
IDE updates the ArduinoState
after the successful command execution:
Arduino IDE version
2.3.4
Operating system
macOS
Operating system version
15.3.1
Additional context
No response
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