Comments (13)
I use 'gd' to jump to definition which worked fine initially, then I ctrl-o jump back and try gd on a different function then it reports "buffer 1 not create" and refuse to jump
Tested with vim 9.1 and latest coc.nvim with clangd, can't reproduce.
it works well but jump to declaration instead of definition, is the default gd jump to declarations?
How do you set your gd
mapping? coc.nvim didn't set default gd
.
coc.nvim requests to language server, handle the jumping with locations, before jumping to the document buffer that created and attached. The buffer 1 not created
means the buffer is not created.
[attach] - receive notification: detach
It's strange that coc.nvim received detach
event to detach the buffer.
from coc.nvim.
I used the default suggestion in coc.nvim github:
nmap gd (coc-definition)
nmap gy (coc-type-definition)
nmap gi (coc-implementation)
nmap gr (coc-references)
this has been a while, and it occurs to me on various languages and is always reproducible, I don't know how to debug this and not sure if it's caused by something else.
from coc.nvim.
it's very odd, I just tried to change .vimrc, it works without issues, I can recover the original .vimrc, it still works, now not sure what is going on, but it works for the moment.
from coc.nvim.
occurs to me on various languages
What's the language server?
from coc.nvim.
when it happens it seems to be LSP irrelevant, I tested clangd and tsserver
from coc.nvim.
Needs a way to reproduce to debug the issue.
from coc.nvim.
will try to find it out, it just came back, not sure if .vimrc caused it since changing .vimrc does make some difference, need check more closely, thanks.
from coc.nvim.
Try to bisect your vimrc
from coc.nvim.
did that before, so far the pattern is:
while in the bisect, when my vimrc halves to a certain size(this varies, today's it's the first 700 line), 'gd' starts to fully work, now if I copy the original failed .vimrc, it still works, in short, when it starts to work, there is no more issues for the day. I'm going to try logout/reboot and see if that changes anything.
from coc.nvim.
bisected to certain lines it starts to work, then it keeps working, even after I copy the original .vimrc back, or after a logout/login, or after a reboot, it keeps working and never dies, this is truly odd.
from coc.nvim.
might be my own problem as I could not reproduce it on another ubuntu 22.04 laptop, but it occurs on my ubuntu 22.04 desktop
from coc.nvim.
## versions
vim version: VIM - Vi IMproved 9.0 9000749
node version: v20.12.2
coc.nvim version: 0.0.82-d1568d56 2023-09-29 19:43:34 +0800
coc.nvim directory: /home/userx/.vim/plugged/coc.nvim
term: dumb
platform: linux
## Log of coc.nvim
2024-04-24T22:13:27.606 WARN (pid:6859) [commands] - Command prettier.createConfigFile already registered
2024-04-24T22:13:27.606 WARN (pid:6859) [commands] - Command prettier.openOutput already registered
2024-04-24T22:13:27.606 WARN (pid:6859) [commands] - Command prettier.forceFormatDocument already registered
2024-04-24T22:13:27.606 WARN (pid:6859) [commands] - Command prettier.formatFile already registered
2024-04-24T22:13:27.650 INFO (pid:6859) [plugin] - coc.nvim initialized with node: v20.12.2 after 411
2024-04-24T22:13:27.658 INFO (pid:6859) [services] - LanguageClient clangd state change: stopped => starting
2024-04-24T22:13:27.663 INFO (pid:6859) [language-client-index] - Language server "clangd" started with 6920
2024-04-24T22:13:27.671 INFO (pid:6859) [services] - LanguageClient clangd state change: starting => running
2024-04-24T22:13:27.675 INFO (pid:6859) [services] - service clangd started
2024-04-24T22:13:27.909 INFO (pid:6859) [core-watchman] - watchman watching project: /home/userx/devel/notes
2024-04-24T22:13:29.407 INFO (pid:6859) [attach] - receive notification: jumpDefinition []
2024-04-24T22:13:31.050 INFO (pid:6859) [attach] - receive notification: detach []
2024-04-24T22:13:32.447 INFO (pid:6859) [attach] - receive notification: jumpDefinition []
2024-04-24T22:13:32.451 ERROR (pid:6859) [attach] - Error on notification jumpDefinition Error: Buffer 1 not created.
at FE.getAttachedDocument (/home/userx/.vim/plugged/coc.nvim/build/index.js:194:3344)
at $y.getCurrentState (/home/userx/.vim/plugged/coc.nvim/build/index.js:277:34038)
at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
at async Iy.request (/home/userx/.vim/plugged/coc.nvim/build/index.js:265:5418)
at async Iy.gotoDefinition (/home/userx/.vim/plugged/coc.nvim/build/index.js:265:6886)
at async Gy.cocAction (/home/userx/.vim/plugged/coc.nvim/build/index.js:277:46159)
at async EventEmitter.<anonymous> (/home/userx/.vim/plugged/coc.nvim/build/index.js:277:47778)
2024-04-24T22:13:39.508 INFO (pid:6859) [attach] - receive notification: showInfo []
now this shows up on both of my ubuntu 22.04, it comes and goes, most of the time it's there. so far I could not track down its root cause, it occurs randomly.
from coc.nvim.
I removed most of my plugins and configuration tweaks, with only coc.nvim and a few must-have plugs, so far there is no issue
from coc.nvim.
Related Issues (20)
- Repeated Diagnostic Messages with Verible Language Server HOT 6
- Can't install any plugins if node is installed inside a folder with a space on Windows HOT 2
- How to stop annoying prompt? HOT 1
- golang lsp gofumpt HOT 1
- ✗ coc-html spawn EINVAL / ✗ coc-pyright spawn EINVAL HOT 1
- Explaining why some LSP needs plugins HOT 1
- coc format behavior differently between Neovim and Vim, create unnecessary empty change in neovim. HOT 8
- something about jumpback after gD coc-definition HOT 2
- 打开rust文件时, coc报错 HOT 2
- Hover/docstring information with custom sources HOT 2
- 为什么会代码提示会提示两次? HOT 5
- [coc.nvim] Server languageserver.ccls failed to start: Error: expected rootUri HOT 1
- Failed open exsit file with list in vim HOT 5
- The text above get seleted automatically HOT 2
- The documentation has incorrect installation instructions for NeoBundle HOT 1
- How to remove the highlights when using go references HOT 3
- LinkedEditing not work in vim HOT 1
- help: completion of variables from dotenv files in shell scripts HOT 9
- <CR> can not confirm in vimwiki and folding codes failed HOT 4
- coc.nvim takes up two shortcut keys that I prefer to use. HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from coc.nvim.