-
-
Notifications
You must be signed in to change notification settings - Fork 369
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
Haskell extension hangs in VSCode #2340
Comments
If you are able to attend the HaskellExchange event next week, I will be giving a talk about HLS performance: https://skillsmatter.com/conferences/13256-haskell-exchange-2021 If you are unable to attend, I expect that the recording will be made available after the event |
For context (and the lazy) the bit that I suppose most people will be interested in: |
Issue still persists on IHP v.017.0 for me unfortunately... Click to expand log
Several processes taking well over 4 minutes. For example: 2021-12-14 16:34:08.102729866 [ThreadId 955] INFO hls: finish: codeLens.TypeCheck (took 4m03s) |
I can't glean much useful information from that log, but I could use an open telemetry log:
|
I've kicked off a build for HLS with To get this running in IHP this is needed in the ihp = builtins.fetchGit {
url = "https://github.com/digitallyinduced/ihp.git";
rev = "3111ba4e8597f627ee7f551a244416adace794a6";
allRefs = true;
}; After that a |
@barnabasmolnar could you give the above steps a try with the |
Yeah sure, I'll definitely have a look. It might well be only after the holidays though. |
I have a similar issue, I think it has to do with the I'm very unfamiliar with the Haskell ecosystem, I'll just present here the results of my investigation. Context: use of HLS within IHP (latest at time of writing) Proper Haskell extensions have been installed, and I've set the debug output level of "Haskell" to "info". EDIT: "solved" by un-installing system-wide GHC, which is not the appropriate solution Out of the boxYou can see the example project on GitHub. When I open a file that doesn't contain hsxI have basic intellisense working in the sense that hovering a variable name tells me where it is defined: And I see in the log info requests being made to the HLS. But as soon as I edit the file I lose that intellisense and I no longer see any messages in the debug output of the Haskell extension. When I open a file that contains hsxI loose intellisense immediately. If I restart the HLS and VSCode, I can see in the status bar that the Haskell extension gets stuck on "Processing 20/27". Messages are sent to the HLS until I start editing something. Enabling QuasiQuotes on files containing hsxWhen I enable QuasiQuotes on the 2 files containing hsx, then:
removing hie.yamlWhen I remove
Any cues please? |
@pepeiborra I ran HLS with eventlog enabled on a single view file in a small IHP project. Here is the tracy file: hls.zip. 7 minutes in the typecheck phase! The project this was ran on can be found here, and the command run for HLS was
Running on WSL Ubuntu. Probe tools:
Reproduceable environment including HLS can be produced running Running on a file without the "hsx" quasiquoter loads almost instantly, e.g. |
UPDATE: compiling HLS with |
Just did a quick check with IHP v0.18.0 and can confirm that HLS now seems to be working almost instantaneously. Great work and a big thank you to everyone involved. 🎉 👍 |
great! thanks for confirming it, i guess it works with building with |
yes exactly 👍 That flag is now enabled for all IHP users that run v0.18 |
I am gonna close this issue as all compiler crashes seems to have the same root cause:
If any of you think the issue should not be included generically feel free to reopen it (with a brief explanation if possible) |
I know it's bad etiquette to comment post issue closure, but since many of us were here because of IHP I thought relevant to confirm that it now works out of the box just following the 3 command install instructions from IHP's official website. Excellent work everyone! What a pleasure to see a lively community at work! |
@mpscholten suggested that I open an issue in this repo.
Here is a log.
The troubleshooting guide didn't help. |
Linked issue on the IHP tracker: digitallyinduced/ihp#1209
When using HLS as part of IHP, either locally inside a WSL2 distro or via a Gitpod instance, the Haskell extension in VSCode hangs for a lot of time before becoming operational. For me, it's usually 4 minutes or so but a friend of mine on a weaker PC reported loading times up to 20-30 minutes.
I've provided some logs below.
Some of the actions that seem to have taken a lot of time are:
Wingman.getMetaprogramsAtSpan.TypeCheck (took 2m17s)
Wingman.codeLensProvider.GetBindings (took 3m34s)
RefineImports (took 3m34s)
When I'm using stack to manage my own Haskell projects, the extension seems to work fine and near instantaneously. Admittedly those projects are far smaller and have fewer files and everything... but ~4 minutes still seems very excessive to me.
Would be curious if anyone had similar issues and whether there might be a fix to speed things up.
Click to expand log
The text was updated successfully, but these errors were encountered: