Skip to content
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

Vue LSP not working #12384

Open
1 task done
Runkunkun opened this issue May 28, 2024 · 12 comments
Open
1 task done

Vue LSP not working #12384

Runkunkun opened this issue May 28, 2024 · 12 comments
Labels
bug [core label] language server An umbrella label for all language servers language An umbrella label for all programming languages syntax behaviors needs info / awaiting response Issue that needs more information from the user vue Vue.js framework support

Comments

@Runkunkun
Copy link

Check for existing issues

  • Completed

Describe the bug / provide steps to reproduce it

Vue Autocompletion and Import stopped working after updating Zed. I already tried deleting the languages and extensions folder, that seemed to fix the problem in the past.

Environment

Zed: v0.136.2 (Zed)
OS: macOS 14.4.1
Memory: 32 GiB
Architecture: aarch64

If applicable, add mockups / screenshots to help explain present your vision of the feature

No response

If applicable, attach your ~/Library/Logs/Zed/Zed.log file to this issue.

2024-05-28T17:26:08+02:00 [INFO] Initializing default prettier with plugins {}
2024-05-28T17:26:08+02:00 [INFO] starting language servers for Vue.js: tailwindcss-language-server, eslint, vue-language-server

2024-05-28T17:26:08+02:00 [WARN] Skipping path "/Users/lukas.kurth" that has no prettier dependency and no workspaces section in its package.json
2024-05-28T17:26:08+02:00 [INFO] Language server with id 3 sent unhandled notification eslint/status:
{
"uri": "file:///Users/lukas.kurth/Repositories/cookbook-recipes/components/web-apps/private-recipes/src/components/DynamicImageList.vue",
"state": 1,
"validationTime": 21
}
2024-05-28T17:26:11+02:00 [INFO] Language server with id 3 sent unhandled notification eslint/status:
{
"uri": "file:///Users/lukas.kurth/Repositories/cookbook-recipes/components/web-apps/private-recipes/src/components/DynamicImageList.vue",
"state": 1,
"validationTime": 16
}
2024-05-28T17:26:12+02:00 [INFO] Language server with id 3 sent unhandled notification eslint/status:
{
"uri": "file:///Users/lukas.kurth/Repositories/cookbook-recipes/components/web-apps/private-recipes/src/components/DynamicImageList.vue",
"state": 1,
"validationTime": 15
}
2024-05-28T17:26:13+02:00 [INFO] Language server with id 3 sent unhandled notification eslint/status:
{
"uri": "file:///Users/lukas.kurth/Repositories/cookbook-recipes/components/web-apps/private-recipes/src/components/DynamicImageList.vue",
"state": 1,
"validationTime": 14
}
2024-05-28T17:26:13+02:00 [INFO] Language server with id 3 sent unhandled notification eslint/status:
{
"uri": "file:///Users/lukas.kurth/Repositories/cookbook-recipes/components/web-apps/private-recipes/src/components/DynamicImageList.vue",
"state": 1,
"validationTime": 13
}

@Runkunkun Runkunkun added admin read Pending admin review bug [core label] triage Maintainer needs to classify the issue labels May 28, 2024
@Moshyfawn Moshyfawn added language An umbrella label for all programming languages syntax behaviors language server An umbrella label for all language servers vue Vue.js framework support and removed triage Maintainer needs to classify the issue labels May 28, 2024
@JosephTLyons JosephTLyons removed the admin read Pending admin review label May 28, 2024
@JosephTLyons
Copy link
Collaborator

Hey @Runkunkun - are you still running into the issue or are you able to reproduce it?

@d1y
Copy link
Contributor

d1y commented May 28, 2024

Most likely the same problem as

@Runkunkun
Copy link
Author

Still having the problem, across all my vue projects. Typescript is installed as dev dependency and reinstalling the extension did not fix it, so probably a different Problem than #9388?

@joshuaia
Copy link

Maybe related to #12019
I'm still having this issue.

@jaekong
Copy link

jaekong commented Jun 7, 2024

I am unsure if this is the same case, but in my case it seems like for some reason Zed isn't resolving peerDependencies for vue-language-server, therefore not installing typescript in ~/Library/Application Support/Zed/extensions/work/vue/node_modules

I tried to manually copy and paste typescript from other places, but to no avail. It just deletes everything and re-installs extension again.

2024-06-07T21:30:42+09:00 [INFO] starting language server "vue-language-server", path: "/Users/jae/local_ongoing_works/portfolio-rework/portfolio", id: 9
2024-06-07T21:30:42+09:00 [INFO] Node runtime install_if_needed
2024-06-07T21:30:43+09:00 [INFO] starting language server. binary path: "/Users/jae/Library/Application Support/Zed/node/node-v18.15.0-darwin-arm64/bin/node", working directory: "/Users/jae/local_ongoing_works/portfolio-rework/portfolio", args: ["/Users/jae/Library/Application Support/Zed/extensions/work/vue/node_modules/@vue/language-server/bin/vue-language-server.js", "--stdio"]
2024-06-07T21:30:43+09:00 [ERROR] failed to start language server "vue-language-server": Request initialize failed with message: Can't find typescript.js or tsserverlibrary.js in node_modules/typescript/lib
2024-06-07T21:30:43+09:00 [ERROR] server stderr: Some("")
2024-06-07T21:30:43+09:00 [ERROR] Hit 4 reinstallation attempts for "vue-language-server"
2024-06-07T21:30:43+09:00 [ERROR] crates/lsp/src/lsp.rs:782: oneshot canceled

@freedomlang
Copy link

freedomlang commented Jun 20, 2024

I am unsure if this is the same case, but in my case it seems like for some reason Zed isn't resolving peerDependencies for vue-language-server, therefore not installing typescript in ~/Library/Application Support/Zed/extensions/work/vue/node_modules

I tried to manually copy and paste typescript from other places, but to no avail. It just deletes everything and re-installs extension again.

2024-06-07T21:30:42+09:00 [INFO] starting language server "vue-language-server", path: "/Users/jae/local_ongoing_works/portfolio-rework/portfolio", id: 9
2024-06-07T21:30:42+09:00 [INFO] Node runtime install_if_needed
2024-06-07T21:30:43+09:00 [INFO] starting language server. binary path: "/Users/jae/Library/Application Support/Zed/node/node-v18.15.0-darwin-arm64/bin/node", working directory: "/Users/jae/local_ongoing_works/portfolio-rework/portfolio", args: ["/Users/jae/Library/Application Support/Zed/extensions/work/vue/node_modules/@vue/language-server/bin/vue-language-server.js", "--stdio"]
2024-06-07T21:30:43+09:00 [ERROR] failed to start language server "vue-language-server": Request initialize failed with message: Can't find typescript.js or tsserverlibrary.js in node_modules/typescript/lib
2024-06-07T21:30:43+09:00 [ERROR] server stderr: Some("")
2024-06-07T21:30:43+09:00 [ERROR] Hit 4 reinstallation attempts for "vue-language-server"
2024-06-07T21:30:43+09:00 [ERROR] crates/lsp/src/lsp.rs:782: oneshot canceled

Having the same error message of vue-language-server

Zed: v0.140.5 (Zed)
OS: macOS 14.4.1
Memory: 16 GiB
Architecture: aarch64

@chadsmith12
Copy link

I'm also having an issue with the Vue LSP, and for me I've narrowed down to purely Nuxt vs. a regular Vue Project created by Vite.

If I open up my Nuxt Project inside Zed the Vue LSP Never kicks in and starts up it seems. I can see the following logs for the vue-language-server:

2024-06-25T10:06:03-05:00 [INFO] starting language server. binary path: "/Users/chadsmith/Library/Application Support/Zed/node/node-v18.15.0-darwin-arm64/bin/node", working directory: "/Users/chadsmith/Projects/myproject/src/app", args: ["/Users/chadsmith/Library/Application Support/Zed/extensions/work/vue/node_modules/@vue/language-server/bin/vue-language-server.js", "--stdio"]
2024-06-25T10:06:03-05:00 [ERROR] failed to start language server "vue-language-server": Request initialize failed with message: Can't find typescript.js or tsserverlibrary.js in node_modules/typescript/lib
2024-06-25T10:06:03-05:00 [ERROR] server stderr: Some("")

If I keep that instance of Zed running, and open up a regular Vue project that I created using Vite the LSP in the logs look like that it starts up, but I don't ever receive anything LSP Messages when inside a Vue file or even a TypeScript File.

2024-06-25T10:11:39-05:00 [INFO] starting language servers for Vue.js: tailwindcss-language-server, eslint, vue-language-server

Now if I completely close out all of those Zed instances and only re-open the the regular Vue projected created, the LSP starts to work normally again and I can see the LSP Messages coming in from the vue-language-server in the logs.

Zed: 0.140.5
MacOS: 14.4, 32gb, M2 Max

Hope this information helps any, and let me know if anymore logs could help.

@maxdeviant
Copy link
Member

We just released v0.1.0 of the Vue extension.

Can the folks who are having issues try it out with that version and see if you still encounter the same issues?

If you are still having issues, a project you can share with us that demonstrates the problem would be very helpful in diagnosing and remediating the issue!

@fazulk
Copy link

fazulk commented Jul 31, 2024

This is still an issue, which makes zed un-usable with vue. Although it used to work fine- not sure what happened. Here is a repo you where you can reproduce auto complete not working, as well as go to definition not working within .vue files.

https://github.com/fazulk/vue-zed-demo

@g5becks
Copy link

g5becks commented Aug 25, 2024

Wanted to give zed a try today as well. And the Vue extension is not working for me either.

@github-actions github-actions bot added admin read Pending admin review triage Maintainer needs to classify the issue labels Nov 5, 2024
@notpeter notpeter removed triage Maintainer needs to classify the issue admin read Pending admin review labels Nov 5, 2024
@JosephTLyons
Copy link
Collaborator

Are people still running into this issue?

@JosephTLyons JosephTLyons added the needs info / awaiting response Issue that needs more information from the user label Jan 6, 2025
@jl4nz
Copy link

jl4nz commented Jan 8, 2025

Are people still running into this issue?

Not with the extension, but the @vue/language-server is still hardcoded for 1.8.27.

I do see this [INFO] Language server with id 3 sent unhandled notification eslint/status: if I try 2.2.0 (latest)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug [core label] language server An umbrella label for all language servers language An umbrella label for all programming languages syntax behaviors needs info / awaiting response Issue that needs more information from the user vue Vue.js framework support
Projects
None yet
Development

No branches or pull requests