-
-
Notifications
You must be signed in to change notification settings - Fork 68
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
Error on elm-language-server attach due to node higher than 16 #692
Comments
Did neovim or a plugin that's used for communicating with LSP change? Did you check if |
Enough has changed over the months that trying to bisect for it between neovim versions, plugin versions, and node versions isn't really tractable. There's no plugin necessary for communicating with language servers necessary and fwiw other LSP servers continue to work with my setup. Yes, the tree-sitter.wasm file exists. Mostly I can't even tell what the error is telling me and which project I need to reach out to for help. Can you tell if this is neovim relaying an error back from elmls or if the error originates outside of elmls? |
Also, thanks! |
As it's a |
FWIW Can you provide any advice on how to more directly test elmls in a standalone mode? |
I've been able to track this down to a seeming incompatibility between elm-language-server and Node 18.x. Reverting node to 16.x has resolved the issue for me. Even more weirdly, the issue seems to resolve if I have both 18.x and 16.x installed locally with 18.x first in the path, but is reproducible if only 18.x is installed (via brew). Presumably I'm not the only person using elmls with Node 18.x and this issue involves details more specific to my system. I'm happy to help with further debugging, but otherwise I'll just count the workaround as sufficient for now. |
I was having this issue in Linux with the Helix editor. I used nvm to switch from 18.x to 16.x and that fixed the problem for me as well. |
This fixed my problem :D
|
Might be connected with tree-sitter/tree-sitter#1765 |
@razzeee, the log reported in the first post in this thread is the same as what I've observed when investigating my tree sitter issue, so yeah, it seems to be related to it |
I'm having what looks like the same exact issue and switching node from v18.4.0 back to node v16.14.2 seems to have done the trick. |
Same issue here. I tested using node 16.1.0, 16.16.0, and 18.6.0. Language server provided no feedback on either 16.16.0 or 18.6.0, but works great on 16.1.0. I used both helix editor and vim with ALE, so I wonder if that helps narrow down the problem? |
It needs to be fixed in upstream, nothing we can do in this repo for now. |
One thing is maybe put a warning in the READM E that this might not work versions of node greater than 16.x. I just spent the last several hours trying to get Vim + CoC to work with Elm. It was working, then I brew upgraded vim, and node, and some other things. I just observed of my developers having it on v17.5.0 |
|
I found a workaround in tree-sitter/tree-sitter: Adding
to the top of elm-language-server's index.js makes it work again. |
As far as I understood, it has been fixed in upstream, so we just need a release to happen on their side. |
Reference to potential fix, release pending: |
Worked for me as well (after correcting for typo of missing |
If I am using neovim + lazy, where should I add these few lines? |
@kumkee at the top of index.js in elm-languageserver |
Seems like a release was made three weeks ago now. https://github.com/tree-sitter/tree-sitter/releases/tag/v0.20.8 |
See #954 |
Can this be closed after the latest release? |
I can confirm the update work with node 20.1.0 |
Previously I had a working config for neovim and elm-language-server. I'm not sure if the problem is in elm-language-server, node, or the neovim side.
Expected Behavior
Previous integration worked fine.
Current Behavior
I can confirm that the referenced
tree-sitter.wasm
location exists at that location.Possible Solution
It seems unlikely that elm-language-server itself changed causing the break based on the date of the last release, but I have no idea when I had previously updated my installation. I can't tell from the provided error message if this is a problem from within elmls, an incompatibility with a node upgrade, or an error occurring within neovim.
Steps to Reproduce (for bugs)
Context
elm-language-server integration is now completely non-functional.
Your Environment
Neovim using lsp-config and lsp-installer.
dotfiles available at https://github.com/bwells/dotfiles/tree/master/nvim
The text was updated successfully, but these errors were encountered: