julia-vscode / LanguageServer.jl

An implementation of the Microsoft Language Server Protocol for the Julia language.
Other
364 stars 79 forks source link

an offline mode for the Language Server? #1193

Open mind6 opened 1 year ago

mind6 commented 1 year ago

Not sure if this belongs in the SymbolServer or LanguageServer section.

I periodically get freezes sending commands to the REPL, as the extension stalls on the Language Server querying for cache files. I have a spotty internet connection sometimes and I'd like to run LS in offline mode if possible.

[ Info: Downloading caches...
┌ Info: Couldn't retrieve cache file for InlineStrings.
└   exception = HTTP/1.1 404 Not Found while requesting https://www.julia-vscode.org/symbolcache/store/v1/packages/I/InlineStrings_842dd82b-1e85-43dc-bf29-5d0ee9dffc48/v1.3.1_b5081bd8a53eeb6a2ef956751343ab44543023fb.tar.gz
[ Info: Downloading caches...
┌ Info: Couldn't retrieve cache file for CodeTracking.
└   exception = HTTP/1.1 404 Not Found while requesting https://www.julia-vscode.org/symbolcache/store/v1/packages/C/CodeTracking_da1fd8a2-8d9e-5ec2-8556-3022fb5608a2/v1.1.1_cc4bd91eba9cdbbb4df4746124c22c0832a460d6.tar.gz
[ Info: Downloading caches...
┌ Info: Couldn't retrieve cache file for ExproniconLite.
└   exception = HTTP/1.1 404 Not Found while requesting https://www.julia-vscode.org/symbolcache/store/v1/packages/E/ExproniconLite_55351af7-c7e9-48d6-89ff-24e801d99491/v0.7.6_2321c9c5a07c2658484dacf8e68e3cd8e2470d5d.tar.gz
[ Info: All cache files downloaded.
[ Info: Loading CSV from cache...
┌ Warning: InlineStrings not stored on disc
└ @ SymbolServer c:\Users\kirby\.vscode\extensions\julialang.language-julia-1.38.2\scripts\packages\SymbolServer\src\SymbolServer.jl:247
...
┌ Warning: libblastrampoline_jll not stored on disc
└ @ SymbolServer c:\Users\kirby\.vscode\extensions\julialang.language-julia-1.38.2\scripts\packages\SymbolServer\src\SymbolServer.jl:247
...
┌ Warning: LibSSH2_jll not stored on disc
└ @ SymbolServer c:\Users\kirby\.vscode\extensions\julialang.language-julia-1.38.2\scripts\packages\SymbolServer\src\SymbolServer.jl:247
fredrikekre commented 1 year ago

Perhaps it would be enough to set a connection timeout.

mind6 commented 1 year ago

Perhaps it would be enought to set a connection timeout.

yes, a zero timeout would have the desired effect.

IanButterworth commented 1 year ago

A (short) timeout would be great. I've been experiencing a ~1m40 startup time, most of which appears to be trying cache urls.