sublimelsp / LSP-julia

Julia support for Sublime's LSP plugin using LanguageServer.jl
MIT License
23 stars 1 forks source link

I see too many missing references #26

Open PetrKryslUCSD opened 1 year ago

PetrKryslUCSD commented 1 year ago

https://discourse.julialang.org/t/lsp-missing-reference-woes/98231/13

PetrKryslUCSD commented 1 year ago

Another example: this time a public repository, so feel free to test it yourselves. First, VSCode: image

Now Sublime Text: image

The "troubleshoot the server" information:

# Troubleshooting: julia
## Version
 - LSP: 1.23.0
 - Sublime Text: 4143
## Server Test Run
 - exit code: 0
 - output
## Server Configuration
 - command
```json
[
  "$julia_exe", 
  "--startup-file=no", 
  "--history-file=no", 
  "--project=$server_path", 
  "--eval", 
  "using LanguageServer; runserver()"
]

Active view

Project / Workspace

LSP configuration

## System PATH - C:\Users\pkonl\SublimeJulia-1.8.5\assets\PortableGit\bin - C:\Users\pkonl\SublimeJulia-1.8.5\assets\julia-1.8.5\bin - C:\Users\pkonl\SublimeJulia-1.8.5\assets\PortableGit\mingw64\bin - C:\Users\pkonl\SublimeJulia-1.8.5\assets\PortableGit\usr\bin - C:\Users\pkonl\bin - C:\Program Files\Common Files\Oracle\Java\javapath - C:\Program Files\ImageMagick-7.1.0-Q16-HDRI - C:\SIMULIA\Commands - C:\Program Files\Microsoft MPI\Bin - C:\windows\system32 - C:\windows - C:\windows\System32\Wbem - C:\windows\System32\WindowsPowerShell\v1.0 - C:\windows\System32\OpenSSH - C:\Program Files\Inkscape\bin - C:\Program Files\MATLAB\R2021b\bin - C:\Program Files (x86)\Bitvise SSH Client - C:\Program Files\gs\gs9.56.1\bin - C:\Program Files\ParaView 5.10.0-Windows-Python3.9-msvc2017-AMD64\bin - C:\Program Files\gnuplot\bin - C:\Program Files\Git\cmd - C:\Users\pkonl\AppData\Local\Microsoft\WindowsApps - C:\Users\pkonl\AppData\Local\Programs\MiKTeX\miktex\bin\x64 ``` Is there anything here that would explain the missing references? Many thanks!
PetrKryslUCSD commented 1 year ago

Repo: https://github.com/PetrKryslUCSD/ShellStructureTopo.jl

jwortmann commented 1 year ago

All I can say is that it works on my side and I don't get those missing reference warnings. I do have set "julia.lint.missingrefs": "symbols". But your configuration seems to look fine. Can you confirm that the language server sees the correct environment, i.e. there is Julia env: ShellStructureTopo.jl in the status bar? And to be sure, you do have all dependencies installed with the Julia package manager, right? Like

(@v1.8) pkg> activate .
(ShellStructureTopo) pkg> instantiate

lsp-julia.webm

PetrKryslUCSD commented 1 year ago

Yes, it does show in the status bar, and, yes, I do have all installed.

On Fri, May 5, 2023, 10:20 AM jwortmann @.***> wrote:

All I can say is that it works on my side and I don't get those missing reference warnings. I do have set "julia.lint.missingrefs": "symbols". But your configuration seems to look fine. Can you confirm that the language server sees the correct environment, i.e. there is Julia env: ShellStructureTopo.jl in the status bar? And to be sure, you do have all dependencies installed with the Julia package manager, right? Like

@.***) pkg> activate . (ShellStructureTopo) pkg> instantiate

lsp-julia.webm https://urldefense.com/v3/__https://user-images.githubusercontent.com/6579999/236524289-98543120-376d-4872-8ef2-3c8c5978a524.webm__;!!Mih3wA!E9zLqYLkxBl5ZtPU05V29YFZr3hf4HOSA26onEeqQQMTgGUVMK02AT3e6pIPfcjmB5iRnzxBlPBL20W7BQFYIng7$

— Reply to this email directly, view it on GitHub https://urldefense.com/v3/__https://github.com/sublimelsp/LSP-julia/issues/26*issuecomment-1536555320__;Iw!!Mih3wA!E9zLqYLkxBl5ZtPU05V29YFZr3hf4HOSA26onEeqQQMTgGUVMK02AT3e6pIPfcjmB5iRnzxBlPBL20W7BW-gODhx$, or unsubscribe https://urldefense.com/v3/__https://github.com/notifications/unsubscribe-auth/ACLGGWFIMBYNZLYQM2DM773XEUZEDANCNFSM6AAAAAAXV6LXG4__;!!Mih3wA!E9zLqYLkxBl5ZtPU05V29YFZr3hf4HOSA26onEeqQQMTgGUVMK02AT3e6pIPfcjmB5iRnzxBlPBL20W7BYD2-vTo$ . You are receiving this because you authored the thread.Message ID: @.***>

PetrKryslUCSD commented 1 year ago

How do I debug this?

PetrKryslUCSD commented 1 year ago

Window config: ClientConfig(name='erlang-ls', status_key='lsp_erlang-ls', experimental_capabilities=None, command=['erlang_ls', '--transport', 'stdio'], settings=DottedDict({}), init_options=DottedDict({}), enabled=False, semantic_tokens={}, tcp_port=None, selector='source.erlang', file_watcher={}, env={}, priority_selector='source.erlang', auto_complete_selector=None, path_maps=None, schemes=['file'], disabled_capabilities=DottedDict({})) ClientConfig(name='julia', status_key='lsp_julia', experimental_capabilities=None, command=['$julia_exe', '--startup-file=no', '--history-file=no', '--project=$server_path', '--eval', 'using LanguageServer; runserver()'], settings=DottedDict({'julia': {'completionmode': 'qualify', 'lint': {'run': True, 'modname': True, 'iter': True, 'missingrefs': 'symbols', 'disabledDirs': ['docs', 'test'], 'datadecl': True, 'pirates': True, 'typeparam': True, 'nothingcomp': True, 'constif': True, 'useoffuncargs': True, 'call': True, 'lazy': True}}}), init_options=DottedDict({'julialangTestItemIdentification': True}), enabled=True, semantic_tokens={}, tcp_port=None, selector='source.julia', file_watcher={}, env={}, priority_selector='source.julia', auto_complete_selector=None, path_maps=None, schemes=['file'], disabled_capabilities=DottedDict({})) ClientConfig(name='ocaml', status_key='lsp_ocaml', experimental_capabilities=None, command=['ocaml-language-server', '--stdio'], settings=DottedDict({}), init_options=DottedDict({}), enabled=False, semantic_tokens={}, tcp_port=None, selector='source.reason | source.ocaml', file_watcher={}, env={}, priority_selector='source.reason | source.ocaml', auto_complete_selector=None, path_maps=None, schemes=['file'], disabled_capabilities=DottedDict({})) ClientConfig(name='polymer-ide', status_key='lsp_polymer-ide', experimental_capabilities=None, command=['polymer-editor-service'], settings=DottedDict({'polymer-ide': {'analyzeWholePackage': False, 'fixOnSave': False}}), init_options=DottedDict({}), enabled=False, semantic_tokens={}, tcp_port=None, selector='text.html.basic | source.html | source.js | source.css | source.json', file_watcher={}, env={}, priority_selector='text.html.basic | source.html | source.js | source.css | source.json', auto_complete_selector=None, path_maps=None, schemes=['file'], disabled_capabilities=DottedDict({})) ClientConfig(name='ruby', status_key='lsp_ruby', experimental_capabilities=None, command=['solargraph', 'stdio'], settings=DottedDict({}), init_options=DottedDict({'diagnostics': False}), enabled=False, semantic_tokens={}, tcp_port=None, selector='source.ruby | text.html.ruby', file_watcher={}, env={}, priority_selector='source.ruby | text.html.ruby', auto_complete_selector=None, path_maps=None, schemes=['file'], disabled_capabilities=DottedDict({})) ClientConfig(name='sorbet', status_key='lsp_sorbet', experimental_capabilities=None, command=['srb', 'tc', '--typed', 'true', '--enable-all-experimental-lsp-features', '--lsp', '--disable-watchman'], settings=DottedDict({}), init_options=DottedDict({}), enabled=True, semantic_tokens={}, tcp_port=None, selector='source.ruby | text.html.ruby', file_watcher={}, env={}, priority_selector='source.ruby | text.html.ruby', auto_complete_selector=None, path_maps=None, schemes=['file'], disabled_capabilities=DottedDict({}))

PetrKryslUCSD commented 1 year ago

I am getting this error: image What do you think it means?

PetrKryslUCSD commented 1 year ago

It does not go away when I restart the editor.

PetrKryslUCSD commented 1 year ago

When I run LanguageServer manually, I get:

julia> LanguageServer.runserver();                                                                                              
[ Info: Downloading caches...                                                                                                   
┌ Info: Couldn't retrieve cache file for JuliaFormatter.                                                                        
└   exception = HTTP/1.1 404 Not Found while requesting https://www.julia-vscode.org/symbolcache/store/v1/packages/J/JuliaFormatter_98e50ef6-434e-11e9-1051-2b60c6c9e899/v1.0.27_536ef70e17d2f5b0dcbe5411002721c9bbdfaa05.tar.gz                                
[ Info: Downloading caches...                                                                                                   
┌ Info: Couldn't retrieve cache file for ArrayInterfaceStaticArrays.                                                            
└   exception = HTTP/1.1 404 Not Found while requesting https://www.julia-vscode.org/symbolcache/store/v1/packages/A/ArrayInterfaceStaticArrays_b0d46f97-bff5-4637-a19a-dd75974142cd/v0.1.5_f12dc65aef03d0a49650b20b2fdaf184928fd886.tar.gz                     
[ Info: Downloading caches...                                                                                                   
┌ Info: Couldn't retrieve cache file for BitTwiddlingConvenienceFunctions.                                                      
└   exception = HTTP/1.1 404 Not Found while requesting https://www.julia-vscode.org/symbolcache/store/v1/packages/B/BitTwiddlingConvenienceFunctions_62783981-4cbd-42fc-bca8-16325de8dc4b/v0.1.5_0c5f81f47bbbcf4aea7b2959135713459170798b.tar.gz               
[ Info: Downloading caches...                                                                                                   
┌ Info: Couldn't retrieve cache file for IrrationalConstants.                                                                   
└   exception = HTTP/1.1 404 Not Found while requesting https://www.julia-vscode.org/symbolcache/store/v1/packages/I/IrrationalConstants_92d709cd-6900-40b7-9082-c6be49f344b6/v0.2.2_630b497eafcc20001bba38a4651b327dcfc491d2.tar.gz                            
[ Info: Downloading caches...                                                                                                   
┌ Info: Couldn't retrieve cache file for DiffRules.                                                                             
└   exception = HTTP/1.1 404 Not Found while requesting https://www.julia-vscode.org/symbolcache/store/v1/packages/D/DiffRules_b552c78f-8df3-52c6-915a-8e097449b14b/v1.13.0_a4ad7ef19d2cdc2eff57abbbe68032b1cd0bd8f8.tar.gz                                     
[ Info: Downloading caches...                                                                                                   
┌ Info: Couldn't retrieve cache file for Adapt.                                                                                 
└   exception = HTTP/1.1 404 Not Found while requesting https://www.julia-vscode.org/symbolcache/store/v1/packages/A/Adapt_79e6a3ab-5dfb-504d-930d-738a2a938a0e/v3.6.1_cc37d689f599e8df4f464b2fa3870ff7db7492ef.tar.gz                                          
[ Info: Downloading caches...                                                                                                   
┌ Info: Couldn't retrieve cache file for OffsetArrays.                                                                          
└   exception = HTTP/1.1 404 Not Found while requesting https://www.julia-vscode.org/symbolcache/store/v1/packages/O/OffsetArrays_6fe1bfb0-de20-5000-8ca7-80f57d26f881/v1.12.9_82d7c9e310fe55aa54996e6f7f94674e2a38fcb4.tar.gz                                  
[ Info: Downloading caches...                                                                                                   
┌ Info: Couldn't retrieve cache file for VectorizationBase.                                                                     
└   exception = HTTP/1.1 404 Not Found while requesting https://www.julia-vscode.org/symbolcache/store/v1/packages/V/VectorizationBase_3d5dd08c-fd9d-11e8-17fa-ed2836048c2f/v0.21.58_4c59c2df8d2676c4691a39fa70495a6db0c5d290.tar.gz                            
[ Info: Downloading caches...                                                                                                   
┌ Info: Couldn't retrieve cache file for Revise.                                                                                
└   exception = HTTP/1.1 404 Not Found while requesting https://www.julia-vscode.org/symbolcache/store/v1/packages/R/Revise_295af30f-e4ad-537b-8983-00126c2a3abe/v3.5.2_feafdc70b2e6684314e188d95fe66d116de834a7.tar.gz                                         
[ Info: Downloading caches...                                                                                                   
┌ Info: Couldn't retrieve cache file for LayoutPointers.                                                                        
└   exception = HTTP/1.1 404 Not Found while requesting https://www.julia-vscode.org/symbolcache/store/v1/packages/L/LayoutPointers_10f19ff3-798f-405d-979b-55457f8fc047/v0.1.13_0ad6f0c51ce004dadc24a28a0dfecfb568e52242.tar.gz                                
[ Info: Downloading caches...                                                                                                   
┌ Info: Couldn't retrieve cache file for JSON.                                                                                  
└   exception = HTTP/1.1 404 Not Found while requesting https://www.julia-vscode.org/symbolcache/store/v1/packages/J/JSON_682c06a0-de6a-54ab-a142-c8b1cf79cde6/v0.21.4_31e996f0a15c7b280ba9f76636b3ff9e2ae58c9a.tar.gz                                          
[ Info: Downloading caches...                                                                                                   
┌ Info: Couldn't retrieve cache file for TestItemDetection.                                                                     
└   exception = HTTP/1.1 404 Not Found while requesting https://www.julia-vscode.org/symbolcache/store/v1/packages/T/TestItemDetection_76b0de8b-5c4b-48ef-a724-914b33ca988d/v0.2.0_c63abb8bf01ba3f0e5421760454d578ee9bd12ca.tar.gz                              
[ Info: Downloading caches...                                                                                                   
┌ Info: Couldn't retrieve cache file for Preferences.                                                                           
└   exception = HTTP/1.1 404 Not Found while requesting https://www.julia-vscode.org/symbolcache/store/v1/packages/P/Preferences_21216c6a-2e73-6563-6e65-726566657250/v1.4.0_7eb1686b4f04b82f96ed7a4ea5890a4f0c7a09f1.tar.gz                                    
[ Info: Downloading caches...                                                                                                   
┌ Info: Couldn't retrieve cache file for JuliaInterpreter.                                                                      
└   exception = HTTP/1.1 404 Not Found while requesting https://www.julia-vscode.org/symbolcache/store/v1/packages/J/JuliaInterpreter_aa1ae85d-cabe-5617-a682-6adf51b2e16a/v0.9.23_6a125e6a4cb391e0b9adbd1afa9e771c2179f8ef.tar.gz                              
[ Info: Downloading caches...                                                                                                   
┌ Info: Couldn't retrieve cache file for VTKBase.                                                                               
└   exception = HTTP/1.1 404 Not Found while requesting https://www.julia-vscode.org/symbolcache/store/v1/packages/V/VTKBase_4004b06d-e244-455f-a6ce-a5f9919cc534/v1.0.1_c2d0db3ef09f1942d08ea455a9e252594be5f3b6.tar.gz                                        
[ Info: Downloading caches...                                                                                                   
┌ Info: Couldn't retrieve cache file for SpecialFunctions.                                                                      
└   exception = HTTP/1.1 404 Not Found while requesting https://www.julia-vscode.org/symbolcache/store/v1/packages/S/SpecialFunctions_276daf66-3868-5448-9aa4-cd146d93841b/v2.2.0_ef28127915f4229c971eb43f3fc075dd3fe91880.tar.gz                               
[ Info: Downloading caches...                                                                                                   
┌ Info: Couldn't retrieve cache file for LanguageServer.                                                                        
└   exception = HTTP/1.1 404 Not Found while requesting https://www.julia-vscode.org/symbolcache/store/v1/packages/L/LanguageServer_2b0e0bc5-e4fd-59b4-8912-456d1b03d8d7/v4.4.0_435e26f5767a756861bea4e406a109bee2442254.tar.gz                                 
[ Info: Downloading caches...                                                                                                   
┌ Info: Couldn't retrieve cache file for LoweredCodeUtils.                                                                      
└   exception = HTTP/1.1 404 Not Found while requesting https://www.julia-vscode.org/symbolcache/store/v1/packages/L/LoweredCodeUtils_6f1432cf-f94c-5a45-995e-cdbf5db27b0b/v2.3.0_60168780555f3e663c536500aa790b6368adc02a.tar.gz                               
[ Info: Downloading caches...                                                                                                   
┌ Info: Couldn't retrieve cache file for Parsers.                                                                               
└   exception = HTTP/1.1 404 Not Found while requesting https://www.julia-vscode.org/symbolcache/store/v1/packages/P/Parsers_69de0a69-1ddd-5017-9359-2bf0b02dc9f0/v2.5.8_478ac6c952fddd4399e71d4779797c538d0ff2bf.tar.gz                                        
[ Info: Downloading caches...                                                                                                   
┌ Info: Couldn't retrieve cache file for CPUSummary.                                                                            
└   exception = HTTP/1.1 404 Not Found while requesting https://www.julia-vscode.org/symbolcache/store/v1/packages/C/CPUSummary_2a0fbf3d-bb9c-48f3-b0a9-814d99fd7ab9/v0.2.2_2c144ddb46b552f72d7eafe7cc2f50746e41ea21.tar.gz                                     
[ Info: Downloading caches...                                                                                                   
┌ Info: Couldn't retrieve cache file for ChunkSplitters.                                                                        
└   exception = HTTP/1.1 404 Not Found while requesting https://www.julia-vscode.org/symbolcache/store/v1/packages/C/ChunkSplitters_ae650224-84b6-46f8-82ea-d812ca08434e/v1.0.0_47952f11225e834eb3125184eeea4f6b8c8d934b.tar.gz                                 
[ Info: Downloading caches...                                                                                                   
┌ Info: Couldn't retrieve cache file for LoopVectorization.                                                                     
└   exception = HTTP/1.1 404 Not Found while requesting https://www.julia-vscode.org/symbolcache/store/v1/packages/L/LoopVectorization_bdcacae8-1622-11e9-2a5c-532679323890/v0.12.150_9696a80c21a56b937e3fd89e972f8db5db3186e2.tar.gz                           
[ Info: Downloading caches...                                                                                                   
┌ Info: Couldn't retrieve cache file for DataAPI.                                                                               
└   exception = HTTP/1.1 404 Not Found while requesting https://www.julia-vscode.org/symbolcache/store/v1/packages/D/DataAPI_9a962f9c-6df0-11e9-0e5d-c546b8b5ee8a/v1.14.0_e8119c1a33d267e16108be441a287a6981ba1630.tar.gz                                       
[ Info: Downloading caches...                                                                                                   
┌ Info: Couldn't retrieve cache file for StaticArrays.                                                                          
└   exception = HTTP/1.1 404 Not Found while requesting https://www.julia-vscode.org/symbolcache/store/v1/packages/S/StaticArrays_90137ffa-7385-5640-81b9-e52037218182/v1.5.24_c262c8e978048c2b095be1672c9bee55b4619521.tar.gz                                  
[ Info: Downloading caches...                                                                                                   
┌ Info: Couldn't retrieve cache file for CommonMark.                                                                            
└   exception = HTTP/1.1 404 Not Found while requesting https://www.julia-vscode.org/symbolcache/store/v1/packages/C/CommonMark_a80b9123-70ca-4bc0-993e-6e3bcb318db6/v0.8.12_532c4185d3c9037c0237546d817858b23cf9e071.tar.gz                                    
[ Info: Downloading caches...                                                                                                   
┌ Info: Couldn't retrieve cache file for PrecompileTools.                                                                       
└   exception = HTTP/1.1 404 Not Found while requesting https://www.julia-vscode.org/symbolcache/store/v1/packages/P/PrecompileTools_aea7be01-6a6a-4083-8856-8a6e6704d82a/v1.1.0_d0984cc886c48e5a165705ce65236dc2ec467b91.tar.gz                                
[ Info: Downloading caches...                                                                                                   
┌ Info: Couldn't retrieve cache file for NaNMath.                                                                               
└   exception = HTTP/1.1 404 Not Found while requesting https://www.julia-vscode.org/symbolcache/store/v1/packages/N/NaNMath_77ba4419-2d1f-58cd-9bb1-8ffee604a2e3/v1.0.2_0877504529a3e5c3343c6f8b4c0381e57e4387e4.tar.gz                                        
[ Info: Downloading caches...                                                                                                   
┌ Info: Couldn't retrieve cache file for ArrayInterfaceStaticArraysCore.                                                        
└   exception = HTTP/1.1 404 Not Found while requesting https://www.julia-vscode.org/symbolcache/store/v1/packages/A/ArrayInterfaceStaticArraysCore_dd5226c6-a4d4-4bc7-8575-46859f9c95b9/v0.1.4_01a9f8e6cfc2bfdd01d333f70b8014a04893103c.tar.gz                 
[ Info: Downloading caches...                                                                                                   
┌ Info: Couldn't retrieve cache file for MeshCore.                                                                              
└   exception = HTTP/1.1 404 Not Found while requesting https://www.julia-vscode.org/symbolcache/store/v1/packages/M/MeshCore_43a99bba-f459-4d0e-8139-f3df11d847d4/v1.3.2_624ed97ba3b64036ec0da793407997ba63a7969c.tar.gz                                       
[ Info: Downloading caches...                                                                                                   
┌ Info: Couldn't retrieve cache file for Tokenize.                                                                              
└   exception = HTTP/1.1 404 Not Found while requesting https://www.julia-vscode.org/symbolcache/store/v1/packages/T/Tokenize_0796e94c-ce3b-5d07-9a54-7f471281c624/v0.5.25_90538bf898832b6ebd900fa40f223e695970e3a5.tar.gz                                      
[ Info: Downloading caches...                                                                                                   
┌ Info: Couldn't retrieve cache file for ArrayInterfaceCore.                                                                    
└   exception = HTTP/1.1 404 Not Found while requesting https://www.julia-vscode.org/symbolcache/store/v1/packages/A/ArrayInterfaceCore_30b0a656-2188-435a-8636-2ec0e6a096e2/v0.1.29_e5f08b5689b1aad068e01751889f2f615c7db36d.tar.gz                            
[ Info: Downloading caches...                                                                                                   
┌ Info: Couldn't retrieve cache file for FinEtools.                                                                             
└   exception = HTTP/1.1 404 Not Found while requesting https://www.julia-vscode.org/symbolcache/store/v1/packages/F/FinEtools_91bb5406-6c9a-523d-811d-0644c4229550/v6.1.2_ac75a357026936b6a888ce5b5b3d487301df1b74.tar.gz                                      
[ Info: Downloading caches...                                                                                                   
┌ Info: Couldn't retrieve cache file for URIs.                                                                                  
└   exception = HTTP/1.1 404 Not Found while requesting https://www.julia-vscode.org/symbolcache/store/v1/packages/U/URIs_5c2747f8-b7ea-4ff2-ba2e-563bfd36b1d4/v1.4.2_074f993b0ca030848b897beff716d93aca60f06a.tar.gz                                           
[ Info: Downloading caches...                                                                                                   
┌ Info: Couldn't retrieve cache file for HostCPUFeatures.                                                                       
└   exception = HTTP/1.1 404 Not Found while requesting https://www.julia-vscode.org/symbolcache/store/v1/packages/H/HostCPUFeatures_3e5b6fbb-0976-4d2c-9146-d79de83f2fb0/v0.1.14_734fd90dd2f920a2f1921d5388dcebe805b262dc.tar.gz                               
[ Info: Downloading caches...                                                                                                   
┌ Info: Couldn't retrieve cache file for MeshSteward.                                                                           
└   exception = HTTP/1.1 404 Not Found while requesting https://www.julia-vscode.org/symbolcache/store/v1/packages/M/MeshSteward_ffa89bc3-d1bd-4aea-b9f7-e9902d9f56ab/v1.2.2_6dd9ccd713576bfb1dfdc51317aa4a2e265cc438.tar.gz                                    
[ Info: Downloading caches...                                                                                                   
┌ Info: Couldn't retrieve cache file for Graphs.                                                                                
└   exception = HTTP/1.1 404 Not Found while requesting https://www.julia-vscode.org/symbolcache/store/v1/packages/G/Graphs_86223c79-3864-5bf0-83f7-82e725a168b6/v1.8.0_1cf1d7dcb4bc32d7b4a5add4232db3750c27ecb4.tar.gz                                         
[ Info: Downloading caches...                                                                                                   
┌ Info: Couldn't retrieve cache file for OrderedCollections.                                                                    
└   exception = HTTP/1.1 404 Not Found while requesting https://www.julia-vscode.org/symbolcache/store/v1/packages/O/OrderedCollections_bac558e1-5e72-5ebc-8fee-abe8a469f55d/v1.6.0_d321bf2de576bf25ec4d3e4360faca399afca282.tar.gz                             
[ Info: Downloading caches...                                                                                                   
┌ Info: Couldn't retrieve cache file for ThreadingUtilities.                                                                    
└   exception = HTTP/1.1 404 Not Found while requesting https://www.julia-vscode.org/symbolcache/store/v1/packages/T/ThreadingUtilities_8290d209-cae3-49c0-8002-c8c24d57dab5/v0.5.1_c97f60dd4f2331e1a495527f80d242501d2f9865.tar.gz                             
[ Info: Downloading caches...                                                                                                   
┌ Info: Couldn't retrieve cache file for TranscodingStreams.                                                                    
└   exception = HTTP/1.1 404 Not Found while requesting https://www.julia-vscode.org/symbolcache/store/v1/packages/T/TranscodingStreams_3bb67fe8-82b1-5028-8e26-92a6c54297fa/v0.9.13_9a6ae7ed916312b41236fcef7e0af564ef934769.tar.gz                            
[ Info: Downloading caches...                                                                                                   
┌ Info: Couldn't retrieve cache file for ChainRulesCore.                                                                        
└   exception = HTTP/1.1 404 Not Found while requesting https://www.julia-vscode.org/symbolcache/store/v1/packages/C/ChainRulesCore_d360d2e6-b24c-11e9-a2a3-2a2ae2dbcce4/v1.15.7_c6d890a52d2c4d55d326439580c3b8d0875a77d9.tar.gz                                
[ Info: Downloading caches...                                                                                                   
┌ Info: Couldn't retrieve cache file for Metis.                                                                                 
└   exception = HTTP/1.1 404 Not Found while requesting https://www.julia-vscode.org/symbolcache/store/v1/packages/M/Metis_2679e427-3c69-5b7f-982b-ece356f1e94b/v1.4.0_66a4f74edb3ac5f28c74de60f9acc2a541fbbe28.tar.gz                                          
[ Info: Downloading caches...                                                                                                   
┌ Info: Couldn't retrieve cache file for SnoopPrecompile.                                                                       
└   exception = HTTP/1.1 404 Not Found while requesting https://www.julia-vscode.org/symbolcache/store/v1/packages/S/SnoopPrecompile_66db9d55-30c0-4569-8b51-7e840670fc0c/v1.0.3_e760a70afdcd461cf01a575947738d359234665c.tar.gz                                
[ Info: Downloading caches...                                                                                                   
┌ Info: Couldn't retrieve cache file for PolyesterWeave.                                                                        
└   exception = HTTP/1.1 404 Not Found while requesting https://www.julia-vscode.org/symbolcache/store/v1/packages/P/PolyesterWeave_1d0040c9-8b98-4ee7-8388-3f51789ca0ad/v0.2.1_240d7170f5ffdb285f9427b92333c3463bf65bf6.tar.gz                                 
[ Info: Downloading caches...                                                                                                   
┌ Info: Couldn't retrieve cache file for ArrayInterface.                                                                        
└   exception = HTTP/1.1 404 Not Found while requesting https://www.julia-vscode.org/symbolcache/store/v1/packages/A/ArrayInterface_4fba245c-0d91-5ea0-9b3e-6abc04ee57a9/v6.0.25_dedc16cbdd1d32bead4617d27572f582216ccf23.tar.gz                                
[ Info: Downloading caches...                                                                                                   
┌ Info: Couldn't retrieve cache file for ForwardDiff.                                                                           
└   exception = HTTP/1.1 404 Not Found while requesting https://www.julia-vscode.org/symbolcache/store/v1/packages/F/ForwardDiff_f6369f11-7733-5829-9624-2563aa707210/v0.10.35_00e252f4d706b3d55a8863432e742bf5717b498d.tar.gz                                  
[ Info: Downloading caches...                                                                                                   
┌ Info: Couldn't retrieve cache file for JSONRPC.                                                                               
└   exception = HTTP/1.1 404 Not Found while requesting https://www.julia-vscode.org/symbolcache/store/v1/packages/J/JSONRPC_b9b8584e-8fd3-41f9-ad0c-7255d428e418/v1.3.6_2756e5ffc7d46857e310a461aa366bbf7bbb673a.tar.gz                                        
[ Info: Downloading caches...                                                                                                   
┌ Info: Couldn't retrieve cache file for WriteVTK.                                                                              
└   exception = HTTP/1.1 404 Not Found while requesting https://www.julia-vscode.org/symbolcache/store/v1/packages/W/WriteVTK_64499a7a-5c06-52f2-abe2-ccb03c286192/v1.18.0_7b46936613e41cfe1c6a5897d243ddcab8feabec.tar.gz                                      
[ Info: Downloading caches...                                                                                                   
┌ Info: Couldn't retrieve cache file for TestItems.                                                                             
└   exception = HTTP/1.1 404 Not Found while requesting https://www.julia-vscode.org/symbolcache/store/v1/packages/T/TestItems_1c621080-faea-4a02-84b6-bbd5e436b8fe/v0.1.1_8621ba2637b49748e2dc43ba3d84340be2938022.tar.gz                                      
[ Info: Downloading caches...                                                                                                   
┌ Info: Couldn't retrieve cache file for FillArrays.                                                                            
└   exception = HTTP/1.1 404 Not Found while requesting https://www.julia-vscode.org/symbolcache/store/v1/packages/F/FillArrays_1a297f60-69ca-5386-bcde-b61e274b549b/v1.0.0_fc86b4fd3eff76c3ce4f5e96e2fdfa6282722885.tar.gz                                     
[ Info: Downloading caches...                                                                                                   
┌ Info: Couldn't retrieve cache file for DataDrop.                                                                              
└   exception = HTTP/1.1 404 Not Found while requesting https://www.julia-vscode.org/symbolcache/store/v1/packages/D/DataDrop_aa547a04-dd37-49ab-8e73-656744f8a8fc/v0.1.3_d64a2312d5c5e213a4390755cf1505c6dc0c4c66.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.3.1_d730914ef30a06732bdd9f763f6cc32e92ffbff1.tar.gz                                   
[ Info: Downloading caches...                                                                                                   
┌ Info: Couldn't retrieve cache file for LogExpFunctions.                                                                       
└   exception = HTTP/1.1 404 Not Found while requesting https://www.julia-vscode.org/symbolcache/store/v1/packages/L/LogExpFunctions_2ab3a3ac-af41-5b50-aa03-7779005ae688/v0.3.23_0a1b7c2863e44523180fdb3146534e265a91870b.tar.gz                               
[ Info: Downloading caches...                                                                                                   
┌ Info: Couldn't retrieve cache file for ArrayInterfaceOffsetArrays.                                                            
└   exception = HTTP/1.1 404 Not Found while requesting https://www.julia-vscode.org/symbolcache/store/v1/packages/A/ArrayInterfaceOffsetArrays_015c0d05-e682-4f19-8f0a-679ce4c54826/v0.1.7_3d1a9a01976971063b3930d1aed1d9c4af0817f8.tar.gz                     
[ Info: Downloading caches...                                                                                                   
┌ Info: Couldn't retrieve cache file for CloseOpenIntervals.                                                                    
└   exception = HTTP/1.1 404 Not Found while requesting https://www.julia-vscode.org/symbolcache/store/v1/packages/C/CloseOpenIntervals_fb6a15b2-703c-40df-9091-08a04967cfa9/v0.1.11_d61300b9895f129f4bd684b2aff97cf319b6c493.tar.gz                            
[ Info: Downloading caches...                                                                                                   
┌ Info: Couldn't retrieve cache file for Static.                                                                                
└   exception = HTTP/1.1 404 Not Found while requesting https://www.julia-vscode.org/symbolcache/store/v1/packages/S/Static_aedffcd0-7271-4cad-89d0-dc628f76c6d3/v0.8.6_08be5ee09a7632c32695d954a602df96a877bf0d.tar.gz                                         
[ Info: Downloading caches...                                                                                                   
┌ Info: Couldn't retrieve cache file for StatsAPI.                                                                              
└   exception = HTTP/1.1 404 Not Found while requesting https://www.julia-vscode.org/symbolcache/store/v1/packages/S/StatsAPI_82ae8749-77ed-4fe6-ae5f-f523153014b0/v1.6.0_45a7769a04a3cf80da1c1c7c60caf932e6f4c9f7.tar.gz                                       
[ Info: Downloading caches...                                                                                                   
┌ Info: Couldn't retrieve cache file for SLEEFPirates.                                                                          
└   exception = HTTP/1.1 404 Not Found while requesting https://www.julia-vscode.org/symbolcache/store/v1/packages/S/SLEEFPirates_476501e8-09a2-5ece-8869-fb82de89a1fa/v0.6.38_cda0aece8080e992f6370491b08ef3909d1c04e7.tar.gz                                  
[ Info: Downloading caches...                                                                                                   
┌ Info: Couldn't retrieve cache file for Compat.                                                                                
└   exception = HTTP/1.1 404 Not Found while requesting https://www.julia-vscode.org/symbolcache/store/v1/packages/C/Compat_34da2185-b29b-5c13-b0c7-acf172513d20/v3.46.2_6c0100a8cf4ed66f66e2039af7cde3357814bad2.tar.gz                                        
[ Info: Downloading caches...                                                                                                   
┌ Info: Couldn't retrieve cache file for InverseFunctions.                                                                      
└   exception = HTTP/1.1 404 Not Found while requesting https://www.julia-vscode.org/symbolcache/store/v1/packages/I/InverseFunctions_3587e190-3f89-42d0-90ee-14403ec27112/v0.1.9_6667aadd1cdee2c6cd068128b3d226ebc4fb0c67.tar.gz                               
[ Info: Downloading caches...                                                                                                   
┌ Info: Couldn't retrieve cache file for Glob.                                                                                  
└   exception = HTTP/1.1 404 Not Found while requesting https://www.julia-vscode.org/symbolcache/store/v1/packages/G/Glob_c27321d9-0574-5035-807b-f59d2c89b15c/v1.3.1_97285bbd5230dd766e9ef6749b80fc617126d496.tar.gz                                           
[ Info: Downloading caches...                                                                                                   
┌ Info: Couldn't retrieve cache file for CodecZlib.                                                                             
└   exception = HTTP/1.1 404 Not Found while requesting https://www.julia-vscode.org/symbolcache/store/v1/packages/C/CodecZlib_944b1d66-785c-5afd-91f1-9de20f533193/v0.7.1_9c209fb7536406834aa938fb149964b985de6c83.tar.gz                                      
[ Info: Downloading caches...                                                                                                   
┌ Info: Couldn't retrieve cache file for SortingAlgorithms.                                                                     
└   exception = HTTP/1.1 404 Not Found while requesting https://www.julia-vscode.org/symbolcache/store/v1/packages/S/SortingAlgorithms_a2af1166-a08f-5f64-846c-94a0d3cef48c/v1.1.0_a4ada03f999bd01b3a25dcaa30b2d929fe537e00.tar.gz                              
[ Info: Downloading caches...                                                                                                   
┌ Info: Couldn't retrieve cache file for Missings.                                                                              
└   exception = HTTP/1.1 404 Not Found while requesting https://www.julia-vscode.org/symbolcache/store/v1/packages/M/Missings_e1d29d7a-bbdc-5cf2-9ac0-f12de2c33e28/v1.1.0_f66bdc5de519e8f8ae43bdc598782d35a25b1272.tar.gz                                       
[ Info: Downloading caches...                                                                                                   
┌ Info: Couldn't retrieve cache file for ChangesOfVariables.                                                                    
└   exception = HTTP/1.1 404 Not Found while requesting https://www.julia-vscode.org/symbolcache/store/v1/packages/C/ChangesOfVariables_9e997f8a-9a97-42d5-a9f1-ce6bfc15e2c0/v0.1.7_f84967c4497e0e1955f9a582c232b02847c5f589.tar.gz                             
[ Info: Downloading caches...                                                                                                   
┌ Info: Couldn't retrieve cache file for DocStringExtensions.                                                                   
└   exception = HTTP/1.1 404 Not Found while requesting https://www.julia-vscode.org/symbolcache/store/v1/packages/D/DocStringExtensions_ffbed154-4ef7-542d-bbb7-c09d3a79fcae/v0.9.3_2fb1e02f2b635d0845df5d7c167fec4dd739b00d.tar.gz                            
[ Info: All cache files downloaded.                                                                                             
[ Info: Indexing FinEtools...                                                                                                   
[ Info: Indexing Revise...                                                                                                      
[ Info: Indexing MeshCore...                                                                                                    
[ Info: Indexing LanguageServer...                                                                                              
[ Info: Indexing DataDrop...                                                                                                    
[ Info: Indexing StaticArrays...                                                                                                
[ Info: Indexing Metis...                                                                                                       
[ Info: Indexing MeshSteward...                                                                                                 
┌ Warning: FinEtools not stored on disc                                                                                         
└ @ SymbolServer C:\Users\pkonl\SublimeJulia-1.8.5\assets\.julia-1.8.5-depot\packages\SymbolServer\LMSFX\src\SymbolServer.jl:247┌ Warning: Revise not stored on disc                                                                                            
└ @ SymbolServer C:\Users\pkonl\SublimeJulia-1.8.5\assets\.julia-1.8.5-depot\packages\SymbolServer\LMSFX\src\SymbolServer.jl:247[ Info: Loading Test from cache...                                                                                              
[ Info: Loading Serialization from cache...                                                                                     
[ Info: Loading InteractiveUtils from cache...                                                                                  
[ Info: Loading Markdown from cache...                                                                                          
[ Info: Loading Base64 from cache...                                                                                            
[ Info: Loading Random from cache...                                                                                            
[ Info: Loading SHA from cache...                                                                                               
[ Info: Loading Logging from cache...                                                                                           
┌ Warning: MeshCore not stored on disc                                                                                          
└ @ SymbolServer C:\Users\pkonl\SublimeJulia-1.8.5\assets\.julia-1.8.5-depot\packages\SymbolServer\LMSFX\src\SymbolServer.jl:247[ Info: Loading LinearAlgebra from cache...                                                                                     
┌ Warning: libblastrampoline_jll not stored on disc                                                                             
└ @ SymbolServer C:\Users\pkonl\SublimeJulia-1.8.5\assets\.julia-1.8.5-depot\packages\SymbolServer\LMSFX\src\SymbolServer.jl:247[ Info: Loading Libdl from cache...                                                                                             
┌ Warning: LanguageServer not stored on disc                                                                                    
└ @ SymbolServer C:\Users\pkonl\SublimeJulia-1.8.5\assets\.julia-1.8.5-depot\packages\SymbolServer\LMSFX\src\SymbolServer.jl:247┌ Warning: DataDrop not stored on disc                                                                                          
└ @ SymbolServer C:\Users\pkonl\SublimeJulia-1.8.5\assets\.julia-1.8.5-depot\packages\SymbolServer\LMSFX\src\SymbolServer.jl:247[ Info: Loading REPLHistory from cache...                                                                                       
[ Info: Loading Pkg from cache...                                                                                               
[ Info: Loading Downloads from cache...                                                                                         
[ Info: Loading LibCURL from cache...                                                                                           
[ Info: Loading MozillaCACerts_jll from cache...                                                                                
[ Info: Loading LibCURL_jll from cache...                                                                                       
┌ Warning: LibSSH2_jll not stored on disc                                                                                       
└ @ SymbolServer C:\Users\pkonl\SublimeJulia-1.8.5\assets\.julia-1.8.5-depot\packages\SymbolServer\LMSFX\src\SymbolServer.jl:247┌ Warning: MbedTLS_jll not stored on disc                                                                                       
└ @ SymbolServer C:\Users\pkonl\SublimeJulia-1.8.5\assets\.julia-1.8.5-depot\packages\SymbolServer\LMSFX\src\SymbolServer.jl:247[ Info: Loading nghttp2_jll from cache...                                                                                       
[ Info: Loading Artifacts from cache...                                                                                         
┌ Warning: Zlib_jll not stored on disc                                                                                          
└ @ SymbolServer C:\Users\pkonl\SublimeJulia-1.8.5\assets\.julia-1.8.5-depot\packages\SymbolServer\LMSFX\src\SymbolServer.jl:247[ Info: Loading NetworkOptions from cache...                                                                                    
[ Info: Loading FileWatching from cache...                                                                                      
[ Info: Loading ArgTools from cache...                                                                                          
[ Info: Loading Tar from cache...                                                                                               
[ Info: Loading UUIDs from cache...                                                                                             
[ Info: Loading REPL from cache...                                                                                              
[ Info: Loading Sockets from cache...                                                                                           
[ Info: Loading Unicode from cache...                                                                                           
[ Info: Loading LibGit2 from cache...                                                                                           
[ Info: Loading Printf from cache...                                                                                            
[ Info: Loading Dates from cache...                                                                                             
[ Info: Loading p7zip_jll from cache...                                                                                         
[ Info: Loading TOML from cache...                                                                                              
┌ Warning: StaticArrays not stored on disc                                                                                      
└ @ SymbolServer C:\Users\pkonl\SublimeJulia-1.8.5\assets\.julia-1.8.5-depot\packages\SymbolServer\LMSFX\src\SymbolServer.jl:247┌ Warning: Metis not stored on disc                                                                                             
└ @ SymbolServer C:\Users\pkonl\SublimeJulia-1.8.5\assets\.julia-1.8.5-depot\packages\SymbolServer\LMSFX\src\SymbolServer.jl:247┌ Warning: MeshSteward not stored on disc                                                                                       
└ @ SymbolServer C:\Users\pkonl\SublimeJulia-1.8.5\assets\.julia-1.8.5-depot\packages\SymbolServer\LMSFX\src\SymbolServer.jl:247[ Info: Received new data from Julia Symbol Server.                                                                             

ERROR: InvalidStateException: Channel is closed.                                                                                
Stacktrace:                                                                                                                     
 [1] try_yieldto(undo::typeof(Base.ensure_rescheduled))                                                                         
   @ Base .\task.jl:871                                                                                                         
 [2] wait()                                                                                                                     
   @ Base .\task.jl:931                                                                                                         
 [3] wait(c::Base.GenericCondition{ReentrantLock})                                                                              
   @ Base .\condition.jl:124                                                                                                    
 [4] take_buffered(c::Channel{Any})                                                                                             
   @ Base .\channels.jl:416                                                                                                     
 [5] take!                                                                                                                      
   @ .\channels.jl:410 [inlined]                                                                                                
 [6] get_next_message                                                                                                           
   @ C:\Users\pkonl\SublimeJulia-1.8.5\assets\.julia-1.8.5-depot\packages\JSONRPC\Q0FBr\src\core.jl:214 [inlined]               
 [7] macro expansion                                                                                                            
   @ C:\Users\pkonl\SublimeJulia-1.8.5\assets\.julia-1.8.5-depot\packages\LanguageServer\ad2Yz\src\languageserverinstance.jl:288 [inlined]                                                                                                                      
 [8] (::LanguageServer.var"#113#116"{LanguageServerInstance})()                                                                 
   @ LanguageServer .\task.jl:484                                                                                               
[ Info: Shutting down server instance.                                                                                          

julia> 
PetrKryslUCSD commented 1 year ago

Does it have anything to do with Warning: FinEtools not stored on disc?

jwortmann commented 1 year ago

The missing references and this message are certainly connceted. But I'm not sure what exactly the message means. A quick search on GitHub reveals that it is probably created by https://github.com/julia-vscode/SymbolServer.jl/blob/a7f09c9f31117f403d7fa975dd8f6449f2e2cc93/src/SymbolServer.jl#L248

A difference between Sublime LSP and the VSCode extension is, that here the language server is started with the default arguments using LanguageServer; runserver(), similar to the documented example in https://github.com/julia-vscode/LanguageServer.jl/blob/3a000de8d80b2d374d46517a813882ff1aeb895c/src/runserver.jl#L33-L34. While VSCode uses some custom parameters, with a non-default path for the package cache storage: https://github.com/julia-vscode/julia-vscode/blob/ed2fb65b42d11b6beec51aaaa4703824cfa0fd1c/scripts/languageserver/main.jl#L99

But I can't say wether this could be a reason why it fails to load the package cache for FinEtools on your side.

What is in your Manifest.toml, especially for FinEtools? Maybe there is a bug in SymbolServer.jl for deved packages or something.

PetrKryslUCSD commented 1 year ago

I removed the Manifest.toml, and it was regenerated. No change.

I noticed I had LanguageServer in my Project.toml. I removed that package from the project, and added it to the global julia env. No change.

Note that it isn't only FinEtools. Metis too. And StaticArrays. And MeshCore. All of those "failed to load".

PetrKryslUCSD commented 1 year ago

The Manifest.toml: https://gist.github.com/PetrKryslUCSD/fc67d317f5b05fea4349c602c4bc7129

jwortmann commented 1 year ago

I tried with your Manifest.toml but still can't reproduce the issue.

Whether or not you have added LanguageServer to your global environment shouldn't matter, because LSP-julia creates its own environment to start the language server, with the dependencies pinned to certain commits: https://github.com/sublimelsp/LSP-julia/blob/main/server/Manifest.toml

There are a few issue reports in the VSCode repo, complaining about missing references and the "failed to load" message:

But they are still open after 3 years, and I guess someone with more knowledge about the LanguageServer.jl/SymbolServer.jl internals would have to do the debugging, in order to find the root cause. I don't really think that the bug is related to LSP-julia, because it just starts the server in the most simple way using LanguageServer; runserver(), and has no control about the package indexing or symbol cache loading.

Both of the issue links seem to indicate that it might have something to do with the Julia installation, though (like adjustments to JULIA_DEPOT_PATH).

PetrKryslUCSD commented 1 year ago

I set up I julia installation without an ad hoc depot path: no change, the same problems. This is it, I refuse to lose any more time with LSP. The marginal benefit is just not worth the trouble. Thanks for your help.

PetrKryslUCSD commented 9 months ago

Well, I tried again, after all. Still no luck: https://discourse.julialang.org/t/lsp-documentation-not-shown-for-used-packages/109202