zigtools / zls-vscode

Deprecated, please use https://github.com/ziglang/vscode-zig
https://github.com/ziglang/vscode-zig
MIT License
85 stars 15 forks source link

Supply LanguageClientOptions.connectionOptions.maxRestartCount set to some high value to work around ZLS crash issues #28

Closed 20kdc closed 2 years ago

20kdc commented 2 years ago

ZLS crashes often here. When ZLS restarts, it's usually fine again. When ZLS crashes enough times, however, it becomes unusable, because apparently if a language server crashes enough times the default VSCode behaviour is to turn it off,. In practice this "recovery" behaviour basically makes ZLS unusable.

Reproduction method: Write code until ZLS breaks. IDK. Version of ZLS used: 0.9.0 Version of Zig used: Master https://ziglang.org/builds/zig-linux-x86_64-0.10.0-dev.183+5c228765f.tar.xz Version of extension used: 1.0.0, also seen with integrated ZLS support in prime31 zig support extension.

SuperAuguste commented 2 years ago

VSCode disabling ZLS after a while is intended behavior; ZLS isn't meant to crash so I'll work on fixing the crashing instead of implementing a workaround. :)