lib/solargraph/library.rb:278
When locate_ref method of Library#locate_ref can't find the appropriate location it responds with the workspace variable content (array), therefore Definition#require_location raises above error.
Ideas
The most quickest fix - is returns nil when workspace doesn't have needed location, but it still doesn't have any result. So it's just hotfix.
Prerequisites
My environment:
MacOS 13.4.1
3.2.1
0.49.0
2.0.3
How to reproduce
hanami new web
In order to save your time I published it: https://github.com/RuBAN-GT/hanami-example
Problem place
lib/solargraph/library.rb:278
Whenlocate_ref
method ofLibrary#locate_ref
can't find the appropriate location it responds with theworkspace
variable content (array), thereforeDefinition#require_location
raises above error.Ideas
The most quickest fix - is returns nil when workspace doesn't have needed location, but it still doesn't have any result. So it's just hotfix.