castwide / vscode-solargraph

A Visual Studio Code extension for Solargraph.
Other
423 stars 25 forks source link

Unable to read file #172

Closed NuriYuri closed 4 years ago

NuriYuri commented 4 years ago

Since the last update I get a nasty error when I try to find the definition of anything :

Unable to open '00650+Game_Map_Ext.rb': Unable to read file 'd:\nuriy\Work\pokemonsdk\pokemonsdk\scripts\00650+MapSystem\00650+Game_Map_Ext.rb' 
(Error: Unable to resolve non-existing file 'd:\nuriy\Work\pokemonsdk\pokemonsdk\scripts\00650+MapSystem\00650+Game_Map_Ext.rb').

Solargraph version: 0.39.6 Ruby version : 2.5.7p206 [i386-mingw32] OS: Windows 10 Pro (1903)

I have the current settings for solargraph :

{
  "solargraph.transport": "stdio",
  "solargraph.diagnostics": true
}

I'm using STDIO because with socket the connexion gets often disposed and solargraph never restart while in STDIO solargraph restarts in case of crash.

The open folder with VSCode is the following one : https://gitlab.com/pokemonsdk/pokemonsdk/-/tree/development/scripts

Here's the stat when I run yard doc (with exclusion) :

Files:         334
Modules:        75 (   10 undocumented)
Classes:       283 (   45 undocumented)
Constants:    1004 (  115 undocumented)
Attributes:    669 (    0 undocumented)
Methods:      3109 (  169 undocumented)
 93.40% documented
castwide commented 4 years ago

When VS Code converts a file path with spaces from a URI, it breaks if the spaces are encoded as + instead of %20. It should be fixed in gem 0.39.7, which I just released.

NuriYuri commented 4 years ago

Works well :D

Thanks a lot, I'm closing the issue :)