rockofox / intellij-haskell-lsp

IntelliJ Plugin that provides Haskell language support via haskell-language-server
https://plugins.jetbrains.com/plugin/24123-haskell-lsp
Apache License 2.0
14 stars 4 forks source link

Cannot find haskell-language-server-wrapper #5

Closed sumanthegde closed 4 months ago

sumanthegde commented 4 months ago

macOS. GHC, cabal & HLS are all installed using ghcup. The plugin throws the following error.

com.redhat.devtools.lsp4ij.server.CannotStartProcessException: java.io.IOException: Cannot run program "haskell-language-server-wrapper": error=2, No such file or directory
    at com.redhat.devtools.lsp4ij.server.ProcessStreamConnectionProvider.start(ProcessStreamConnectionProvider.java:68)
    at com.redhat.devtools.lsp4ij.LanguageServerWrapper.lambda$start$0(LanguageServerWrapper.java:231)
    at java.base/java.util.concurrent.CompletableFuture$AsyncSupply.run(CompletableFuture.java:1768)
    at java.base/java.util.concurrent.CompletableFuture$AsyncSupply.exec(CompletableFuture.java:1760)
    at java.base/java.util.concurrent.ForkJoinTask.doExec(ForkJoinTask.java:373)
    at java.base/java.util.concurrent.ForkJoinPool$WorkQueue.topLevelExec(ForkJoinPool.java:1182)
    at java.base/java.util.concurrent.ForkJoinPool.scan(ForkJoinPool.java:1655)
    at java.base/java.util.concurrent.ForkJoinPool.runWorker(ForkJoinPool.java:1622)
    at java.base/java.util.concurrent.ForkJoinWorkerThread.run(ForkJoinWorkerThread.java:165)
Caused by: java.io.IOException: Cannot run program "haskell-language-server-wrapper": error=2, No such file or directory
    at java.base/java.lang.ProcessBuilder.start(ProcessBuilder.java:1143)
    at java.base/java.lang.ProcessBuilder.start(ProcessBuilder.java:1073)
    at com.redhat.devtools.lsp4ij.server.ProcessStreamConnectionProvider.start(ProcessStreamConnectionProvider.java:66)
    ... 8 more
Caused by: java.io.IOException: error=2, No such file or directory
    at java.base/java.lang.ProcessImpl.forkAndExec(Native Method)
    at java.base/java.lang.ProcessImpl.<init>(ProcessImpl.java:314)
    at java.base/java.lang.ProcessImpl.start(ProcessImpl.java:244)
    at java.base/java.lang.ProcessBuilder.start(ProcessBuilder.java:1110)
    ... 10 more
rockofox commented 4 months ago

Thanks for the bug report! I think there's an issue that currently prevents the plugin from properly working with haskell-language-server installed via GHCup. Users have already reported this in a different issue (https://github.com/rockofox/intellij-haskell-lsp/issues/2), but the issue title was unclear, so I renamed and pinned it now. I'm working on a fix, and will tag you once it's finished.

rockofox commented 4 months ago

Duplicate of #2