Closed geekosaur closed 6 months ago
While researching how to get debug output from VS Code, I found something about multi-root workspaces; reading that, it may be that this is a VS Code wart and I need to manually create new roots in my workspace?
Looks like this is indeed some (to me) very unintuitive behavior in VS Code which breaks not only HLS but other language servers if you open files in unrelated projects. Closing.
Your environment
Which OS do you use? Ubuntu 22.04 Which version of GHC do you use and how did you install it? 9.6.4 via GHCup How is your project built (alternative: link to the project)? xmonad-bsa via cabal, ghc hadrian/custom
Which LSP client (editor/plugin) do you use? VS Codium+vscode-haskell Which version of HLS do you use and how did you install it? 2.7.0.1 via GHCup Have you configured HLS in any way (especially: a
hie.yaml
file)? xmonad-bsa doesn't, ghc doesSteps to reproduce
I have VS Code open with two windows:
Expected behaviour
It should take
hie-bios
from the correct project, or possibly run separatehaskell-language-server
sessions for each.Actual behaviour
On startup, I get:
The
hadrian/hie-bios
part comes from ghc'shie.yaml
, but for some reason it's looking for it in the other project.Debug information
Log for
Haskell
:Log for
Haskell (xmonad)
: