Open JakobBruenker opened 2 years ago
Workaround: Instead of (edit: or maybe in addition to) using build-depends
, you can use ghc-options: -plugin-package=<package-name>
. This seems to work.
Maybe this is also related to us setting up plugins wrong? Does your other PR help this?
@michaelpj good question, it might be vaguely related, but the changes I've made so far do not seem to help
Your environment
Ubuntu (under Windows 11 WSL) ghc 9.4.2 via ghcup
Reproduction repo with minimal example: https://github.com/JakobBruenker/a-cabal-error
Which LSP client (editor/plugin) do you use? VS Code, but running haskell-language-server outside of it produces the same error
Which version of HLS do you use and how did you install it? 1.8.0.0 via ghcup
Have you configured HLS in any way (especially: a
hie.yaml
file)? No (though anhie.yaml
file generated via implicit-hie seemed to make no difference)Steps to reproduce
Run haskell-language-server on the reproduction repo linked above
Expected behaviour
There should only be one error,
Variable not in scope: thisShouldBeAnError :: IO ()
Actual behaviour
The expected error appears, but another error appears as well:
This is rather strange, since the .cabal file does contain that dependency, and
cabal test
runs fine.