-
Notifications
You must be signed in to change notification settings - Fork 147
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
Tsserver can not detect the corresponding error messages #813
Comments
Many things could be the reason. Enable LSP logs in your editor and provide them here after reproducing the issue. |
When I switch back to the previous TypeScript file, tsserver doesn't detect any code changes. There are no messages in LspLog. At 18:21:21, executing LspRestart resulted in the following output. Other LSPs like css-lsp and json-lsp don't have this issue. I manage my plugins using lazy.nvim. [WARN][2023-11-16 17:43:24] .../lua/vim/lsp.lua:1637 "buf_attach_client called on unloaded buffer (id: 6): "
[WARN][2023-11-16 17:49:23] .../lua/vim/lsp.lua:1637 "buf_attach_client called on unloaded buffer (id: 7): "
[WARN][2023-11-16 17:50:35] .../lua/vim/lsp.lua:1637 "buf_attach_client called on unloaded buffer (id: 7): "
[WARN][2023-11-16 17:50:41] .../lua/vim/lsp.lua:1637 "buf_attach_client called on unloaded buffer (id: 7): "
[WARN][2023-11-16 17:50:53] .../lua/vim/lsp.lua:1637 "buf_attach_client called on unloaded buffer (id: 7): "
[START][2023-11-16 18:21:21] LSP logging initiated
[WARN][2023-11-16 18:21:21] .../lua/vim/lsp.lua:1637 "buf_attach_client called on unloaded buffer (id: 9): "
[WARN][2023-11-16 18:22:46] .../lua/vim/lsp.lua:1637 "buf_attach_client called on unloaded buffer (id: 9): "
[WARN][2023-11-16 18:25:57] .../lua/vim/lsp.lua:1637 "buf_attach_client called on unloaded buffer (id: 9): " |
There are logs if your LSP is working. And I don't know what the:
means since that's specific to your editor and not the LSP protocol. |
Afterward, I made some attempts and found that when I use version 4.0.0 of the typescript-language-server, the issue no longer occurs. However, when I switch to version 4.1.0 or above, the previous problem arises again. So, I'm wondering if the new versions have made some modifications. |
Obviously new versions have new changes. I've asked about logs. That's the fastest way I can help you. |
Sorry, I checked the Lsp log, but it's too large to pinpoint the issue. I identified the problem through a minimal code configuration. I found that when I set 'set nohidden', the issue arises. However, when I use 'set hidden', the problem disappears. So, could it be a problem caused by buffers? |
I don't know what |
I'm using NeoVim NERDTree. When I open a TypeScript file, tsserver can detect the corresponding error messages. However, when I switch files and return to the previous one, any code modifications aren't detected by tsserver until I use LspRestart to trigger a recheck. What could be the reason for this?
The text was updated successfully, but these errors were encountered: