-
Notifications
You must be signed in to change notification settings - Fork 16
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix HLS in nix development shell #791
Conversation
I'm going to do the same for API 👍 [edit] This is IntersectMBO/cardano-api#561 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Alas it doesn't seem to work locally 🙁
There are two issues:
- Every opened file shows an error regarding
ghcide
(which is even not in the PATH of the shell 🤷) - There's an error regarding
setInitialDynFlags
:
Error condition, please check your setup and/or the issue tracker:
setInitialDynFlags: No entry for "GCC extra via C opts" in "/nix/store/j4f4vdh414qmrfbk0cwh9wv7asxf3b2b-ghc-shell-for-cardano-cli-ghc-9.8.2-env/lib/ghc-9.8.2/lib/settings"
Weirdly, linking seems to work: I can jump from a symbol to its declaration; but I don't have types in hovers.
I had trouble the first time I opened it too, and then compiled manually and retried and it worked :/ @carbolymer, any ideas? Or do you want to do like in Also, are you opening |
@palas> no → git branch --show-current
fix-hls
→ git rev-parse HEAD
fdf235b15a4fe941537f5548fa05af2400a22f15
→ cabal clean
→ cabal build all
→ which has
hash haskell-language-server
→ which haskell-language-server
/nix/store/kdf9gfiabznqsp854z3zkl9f8z2qk01j-haskell-language-server-exe-haskell-language-server-2.8.0.0/bin/haskell-language-server
→ cabal build all
→ code . &
# Still same state as my previous message :-( |
That's my usual workflow. 😄 Also, I'm still frequently killing HLS 2.8 and restarting it because it gets stuck sometimes (less frequently than 2.6 though).
I'm not using dev shell, I have ghc and hls installed on my system. I don't have hls path set, I'm letting neovim do the discovery. |
That is really odd, it is exactly what I get and it works fine. What do you get if you run
@smelc, could you remove the first dir (in my case |
Still I need to rebase and get the CI to pass... |
@palas> no change after deleting the directory and the file you mentioned 🫤
I attached the log from |
@smelc, if |
346cb8e
to
1945e55
Compare
Yep, sounds legit. @palas> here are my version numbers: → code --version
1.90.1
611f9bfce64f25108829dd295f54a6894e87339d
x64 Haskell extension version |
I have |
@palas> Updating the haskell extension got rid of the Anyway I'm approving, let's not block this one on my setup being broken. I'll go with |
@palas> can you give me the output of |
Woohoo found the problem \o/ I had a reference to an old HLS version in |
Changelog
Context
We've had a good experience with HLS 2.8 so we update GHC and HLS to be able to use 2.8.
How to trust this PR
Probably best to just test that it works for you.
Checklist