sublimelsp / LSP-volar

Vue support for Sublime's LSP plugin

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

LSP-Volar stops working (Possibly Node version issue?)

Hobstweedl opened this issue · comments

I'm installing Sublime Text, LSP and LSP-volar on a new mac, and finding that the plugin seems to start to initialize and then stop working, no features such as inlay hints, autocompletion, or warnings/error appear.

I've been able to verify that lsp-eslint works fine, lsp-typescript seems to show me errors in the IDE but inlay hints do not work at all. I have a second older macbook with LSP and ST at the same versions and same configurations and everything works fine. The only difference in setups I can think of is that the older macbook has Node set at v16.13.2 and this new mac is v18.4.0. I haven't been able to find any indicator in the console or logs that anything is failing, it just seems like at a certain point lsp-volar just stops working and turns off. Details attached below, I'm unsure of what else I could provide that would be helpful

log.txt
Troubleshooting.md

You can easily test with bundled Node 16 by opening Preferences: LSP Utils Settings from the command palette and settting

{
  "nodejs_runtime": ["local"],
}

It does look like Volar silently exists soon after starting but there doesn't seem to be anything wrong with the settings so it's either Node version or something in the project if I'd have to guess.

Switching to the local runtime does fix the issue. I guess there's some breaking change in latest Node that affects LSP. Thanks!

I suppose we can at least set a restriction on node version so that the error message is clear when using v18. Have to try it out here when I have some time.

I've tried 18.4.0 and latest 18.16.1 and both worked fine. It might be some incompatibility with the dependencies in your project. Are you able to share your project or create minimal repo that reproduces?