-
Notifications
You must be signed in to change notification settings - Fork 91
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
Compiling HLS with custom bindist creates haskell-language-server-<ghcver>-<customtag>.exe
shim and HLS fails
#1150
Comments
I don't see how that can work. You'd potentially overwrite another version. The problem generally is that there is a discrepancy between ghc version in GHCup and |
@fendor maybe has an idea |
We encountered a similar issue with the same root cause in haskell/vscode-haskell#1151. Afaik, there is no way to trick HLS-wrapper to do what you want in this case, unfortunately. The simplest workaround is to instruct your editor to simply launch the correct HLS binary. However, this general workflow is quite interesting for testing changes, perhaps we can teach the wrapper to be aware of potential additional suffixes? Alternatively, we could try to patch the shim to additionally look for |
Perhaps this also happens on Linux? I'm not sure anymore if this issue belongs to GHCup or to HLS, but perhaps it is worth some note in GHCup when installing a custom HLS? |
I believe so, yeah. It is a joint issue, I believe, the solution needs to be implemented in HLS, but for the best UX we need to coordinate. What do you think about the proposed solution? Do you think having a custom |
haskell-language-server-<ghcver>-<customtag>.exe
shim and HLS failshaskell-language-server-<ghcver>-<customtag>.exe
shim and HLS fails
I think that should be fine. Most editors allow you to specify the binary to be used. |
Thinking about it, if you can specify the binary, you could also simply specify the binary you built with the custom ghc as well, right? Simply avoid the |
Non-numeric versions are a hack (or leniency) of GHCup. I do not think HLS should do anything here. I'm also not sure this edge case is interesting enough to dream up a solution. I do think we could send a post-install warning message in GHCup if we detect such an oddly named hls-wrapper binary. |
After compiling HLS for my 9.6.6-patched GHC (see #1149), the process terminates succesfully:
There is no
haskell-language-server-9.6.6.exe
binary, but there is ahaskell-language-server-wrapper.exe
which fails because the former is missing:My understanding is that compiling HLS should create a
haskell-language-server-<ghcver>.exe
even if the custom ghc has a tag at the end, otherwise HLS-wrapper won't be able to find it.Manually creating the shim works:
The text was updated successfully, but these errors were encountered: