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

Debug Failure. Unexpected node. #896

Closed
directormac opened this issue May 22, 2024 · 5 comments
Closed

Debug Failure. Unexpected node. #896

directormac opened this issue May 22, 2024 · 5 comments

Comments

@directormac
Copy link

   Error  03:56:49 PM notify.error tsserver: 1: <semantic> TypeScript Server Error (5.4.5)
Debug Failure. Unexpected node.
Node ComputedPropertyName was unexpected.
Error: Debug Failure. Unexpected node.
Node ComputedPropertyName was unexpected.

I am using lazyvim as my base, The error only occurs when using bun workspace as the node_modules are hoisted in the workspace root it errors looking for the type hints, When using on a regular ts projects this wont occur only in Bun workspace

@predragnikolic
Copy link
Contributor

I think this issue is more suited in the bun repo.

@directormac
Copy link
Author

I think this issue is more suited in the bun repo.

Well inlay hints works on vscode but not in neovim tho. maybe its the nvim-lspconfig and tsserver always expecting the node_modules directory to exist in the repo dir.

@predragnikolic
Copy link
Contributor

Vs code doesn't use this typescript-language-server.

I'm not sure why you mention inlay hints and how that is related to the above issue. Can you please explain.

You would need to provide steps on how someone can reproduce the same issue, and what the expected and actual behaviors are.

@80avin
Copy link

80avin commented May 25, 2024

I second this.
I have been seeing this very frequently and it goes away when I disable inlayHints. I am also using LazyVim but the project is in Node.JS and not Bun.

@rchl
Copy link
Member

rchl commented May 27, 2024

First of all, when reporting issues, please provide the code (project) that reproduces the issue. Otherwise no one can help you.

Two, I've seen it happening before. Typically Typescript throws such errors when typing, when the code is momentarily invalid (which is normal when typing). It's not something that can be fixed here. At best we could silence those errors.

Ideally this should be reported in Typescript repo.
And note that it should also happen in VSCode as long as it's using the same Typescript version for type checking (by default it uses built-in Typescript version while you might be using project version).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants