I've installed the ZIP version
After unzipping and running, it hangs on index.html (at least 3 minutes). You can close RC9 and start it again and it behaves as expected.
Hi @sterretje . There is a similar issue being tracked here:
opened 09:23PM - 20 Mar 22 UTC
topic: code
type: imperfection
topic: language server
criticality: highest
### Describe the problem
The IDE hangs permanently during the "**Save As...**… " operation under the following conditions:
- IDE was last shut down via "**File > Quit**"
- Currently selected board is from a different platform than the one selected in the previous window
- The language server "**indexing**" process is in progress
### To reproduce
1. Start the Arduino IDE.
1. Select **File > Quit** from the Arduino IDE menus.
❗ This exact shutdown method is required. The bug does not occur after shutting the IDE down via **File > Close** or the native window close control on the title bar (i.e., **X** or **🔴**).
1. Start the Arduino IDE.
1. Select **File > New** from the Arduino IDE menus.
1. Select a board of a different platform from the **Tools > Board** menu in the Arduino IDE.
**ⓘ** e.g., if you originally had "**Arduino Uno**" ("**Arduino AVR Boards**" platform) selected, you could select "**Arduino Nano 33 BLE**" ("**Arduino Mbed OS Nano Boards**" platform).
❗ The issue is timing sensitive, so you will have a short time window if selecting a board from a lightweight platform such as "**Arduino AVR Boards**". The boards of any of the "**Arduino Mbed OS \_\_\_\_ Boards**" platforms are recommended as these provide a large window.
1. Immediately select **File > Save As...** from the Arduino IDE menus.
1. Immediately click the <kbd>**Save**</kbd> button.
❗ This must be done while the IDE is still in the state where it shows something like "**indexing 42/188**" at the left side of the status bar.
🐛 The IDE hangs forever in the state where the window title is "**index.html**" and contains spinning dots:

### Expected behavior
The sketch that was produced by the "**Save As...**" operation is loaded in the Arduino IDE.
### Arduino IDE version
2.0.0-rc5-snapshot-f36df02 Date: 2022-03-17T10:22:00.589Z
### Operating system
Windows
### Operating system version
10
### Additional context
The first version I can reproduce this fault with is https://github.com/arduino/arduino-ide/commit/e6b9d4e2aa0503a0cb99e472051e1e49f487e2c7. I can not reproduce the fault with https://github.com/arduino/arduino-ide/commit/69ac1f4779589d0d21ce3d37c180b3393ad6156c.
The "**Save As...**" process stopped working correctly at https://github.com/arduino/arduino-ide/commit/112153fb965f63d952d126c8244cd3f84f0a1a1b (https://github.com/arduino/arduino-ide/issues/829), so it is possible that the bug was introduced somewhere between https://github.com/arduino/arduino-ide/commit/69ac1f4779589d0d21ce3d37c180b3393ad6156c and https://github.com/arduino/arduino-ide/commit/e6b9d4e2aa0503a0cb99e472051e1e49f487e2c7 but was not visible due to https://github.com/arduino/arduino-ide/issues/829
---
I see the following output printed on the command line after I do a **File > Quit**:
```text
root ERROR Uncaught Exception:
root ERROR Error: Connection got disposed.
at Object.dispose (C:\ide 2\18-arduino-ide_2.0.0-rc5-snapshot-f36df02_Windows_64bit\resources\app\node_modules\vscode-jsonrpc\lib\main.js:904:25)
at C:\ide 2\18-arduino-ide_2.0.0-rc5-snapshot-f36df02_Windows_64bit\resources\app\node_modules\vscode-ws-jsonrpc\lib\socket\connection.js:14:41
at CallbackList.invoke (C:\ide 2\18-arduino-ide_2.0.0-rc5-snapshot-f36df02_Windows_64bit\resources\app\node_modules\vscode-jsonrpc\lib\events.js:62:39)
at Emitter.fire (C:\ide 2\18-arduino-ide_2.0.0-rc5-snapshot-f36df02_Windows_64bit\resources\app\node_modules\vscode-jsonrpc\lib\events.js:121:36)
at closeHandler (C:\ide 2\18-arduino-ide_2.0.0-rc5-snapshot-f36df02_Windows_64bit\resources\app\node_modules\vscode-jsonrpc\lib\main.js:240:26)
at CallbackList.invoke (C:\ide 2\18-arduino-ide_2.0.0-rc5-snapshot-f36df02_Windows_64bit\resources\app\node_modules\vscode-jsonrpc\lib\events.js:62:39)
at Emitter.fire (C:\ide 2\18-arduino-ide_2.0.0-rc5-snapshot-f36df02_Windows_64bit\resources\app\node_modules\vscode-jsonrpc\lib\events.js:121:36)
at WebSocketMessageReader.fireClose (C:\ide 2\18-arduino-ide_2.0.0-rc5-snapshot-f36df02_Windows_64bit\resources\app\node_modules\vscode-jsonrpc\lib\messageReader.js:111:27)
at WebSocketMessageReader.fireClose (C:\ide 2\18-arduino-ide_2.0.0-rc5-snapshot-f36df02_Windows_64bit\resources\app\node_modules\vscode-ws-jsonrpc\lib\socket\reader.js:67:19)
at C:\ide 2\18-arduino-ide_2.0.0-rc5-snapshot-f36df02_Windows_64bit\resources\app\node_modules\vscode-ws-jsonrpc\lib\socket\reader.js:24:18
```
I see the same output printed multiple times after the fault occurs.
---
I suspect it is related to https://github.com/arduino/arduino-ide/issues/657
---
I was only able to reproduce the fault by saving during the language server "indexing" operation triggered by the board selection. The fault did not occur for me when saving during subsequent indexing operation triggered by editing the sketch.
---
I was not able to reproduce the issue with the "**Arduino > Language: Log**" setting enabled.
---
Originally reported at:
- https://forum.arduino.cc/t/saving-files-is-a-crap-shoot/970560/5
- https://forum.arduino.cc/t/freeze-on-save-when-using-save-as/996842
---
Some of the user reports did not match the specific procedure for reproduction I described above, and I have also encountered it occasionally under other conditions.
I believe that the fault can be triggered in other ways, but I wanted to provide a procedure that consistently reproduces the issue and this was the one I happened to discover.
### Issue checklist
- [X] I searched for previous reports in [the issue tracker](https://github.com/arduino/arduino-ide/issues?q=)
- [X] I verified the problem still occurs when using the latest [nightly build](https://github.com/arduino/arduino-ide#nightly-builds)
- [X] My report contains all necessary details
In that case, it occurred following a "Save As...", so it is possible that it is two distinct bugs that only produce the same symptoms.
I found a specific procedure I could follow to reliably reproduce that issue. There have been multiple reports of the problem, some of which did not match that procedure exactly, indicating that it occurs under other conditions. Recently, I found that I was no longer able to reproduce the issue even while following the exact procedure that worked for me before, yet I still experience it at random from time to time. One of the developers has the same problem. So it seems it is one of those very annoying bugs that is either intermittent or pseudo-intermittent due to requiring a specific combination of unknown conditions.
This makes it very difficult to do any investigation or validate any potential fixes.
If anyone is able to find a way to reproduce the fault reliably, please let us know as that would be very helpful for getting this fixed.
In this case, I do not actively save (or save as) a sketch; this is at startup of the IDE.
I understand that; intermittent failures are a bitch.
I tried to reproduce by renaming the zip, extracting to a different directory and running the IDE from there; the issue did not show (twice in a row).
I understand that. As I said:
system
Closed
January 17, 2023, 5:58am
5
This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.