-
-
Notifications
You must be signed in to change notification settings - Fork 435
Neovim: TypeError: server.workspaceFolders.keys is not a function or its return value is not iterable\n at createLs (~/.local/share/nvim/mason/packages/vue-language-server/node_modules/@vue/language-server/lib/hybridModeProject.js:94:193) #4706
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
Comments
It seems to me that this is due to a breaking change introduced by I think this version is pulled because the dependency is declared in package.json as This might only affect vim because the package manager just runs |
As a workaround, if you're using Mason, you can |
@iro-miya Thank you very much! I did exactly as you told and that worked. Your diagnosis was spot on. |
Hi @johnsoncodehk can we pin volar's version for this reason? |
This is caused by upgrading @RayGuo-ergou Yes, we should pin it if we use the Volar alpha version in the future. |
@johnsoncodehk checked, pinned 2.4.0-alpha.20 version solve that issue |
@johnsoncodehk I also found I can avoid this error by using following tentative package.json to install {
"name":"",
"dependencies":{
"@vue/language-server":"2.0.29",
"typescript":"^5.4.2"
},
"overrides": {
"@volar/language-core": "2.4.0-alpha.20",
"@volar/language-server": "2.4.0-alpha.20"
}
} For me, if the next release of |
I'm using emacs with eglot but having the same issues. I installed the language server globally like this:
which installs the following:
but starting the server gives this error:
and if I comment out that code in |
@johnsoncodehk 2.4.0-alpha.20 works for me too. Thanks! |
@johnsoncodehk |
Vue - Official extension or vue-tsc version
2.0.29
VSCode version
None, Im using Neovim 0.10.1
Vue version
3.4.29
TypeScript version
5.4.0
System Info
Steps to reproduce
Attempt to start volar lsp on a .vue file
What is expected?
The LSP to not fail
What is actually happening?
I get the following error:
Any additional comments?
Here is my relevant neovim config:
I have based this on the informaiton provided in the README of this repository.
The directory I am starting neovim form is a base "npm create vue@latest" directory which looks like this:
The text was updated successfully, but these errors were encountered: