-
-
Notifications
You must be signed in to change notification settings - Fork 75
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
Discard results of long-running 'goto definition' requests #534
Comments
Hey @susliko, thanks for opening this. This is a tricky one. At least in nvim-world I'm assuming that since the server attached to your current buffer is the same as the other, the goto definition handler just handles it. You can see this here. So at least in @tgodzik do you know if VS Code behaves the same if you trigger a goto definition and then move to another file? What happens when the response comes back? @susliko I'd recommend bringing this up in the Neovim matrix channel or creating an issue over there to see what the desired behavior should/could be. I'm assuming that this is a bit unique to Scala though seeing that when you first open a workspace it can take a second to index. |
Just as mentioned on the contributors chat, looks like if you change to another file the go to definition will be cancelled, or really once you do another thing in the file. |
Describe the bug
I've been noticing the following behaviour when Metals is just starting or the code was not yet compiled before:
Expected behavior
Buffer is not switched to the one from the 'goto definition' response if active nvim buffer is not the same as at the time of request invocation
Operating system
macOS
Version of Metals
v0.11.9
Commit of nvim-metals
0b9c530
The text was updated successfully, but these errors were encountered: