You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Jul 30, 2020. It is now read-only.
Currently textDocument/codeAction and textDocument/codeLens respond with commands consisting of textedits that should be applied by the client. however, they are supposed to respond with commands that can be sent back to the server using workspace/executeCommand, and this is what at least lsp-mode does.
To support code actions and code lenses correctly, we should respond to workspace/executeCommand. Doing so is simple, we can just quickly reply with a a workspace/applyEdit containing what is currently sent with the codeAction, and for code lenses, we would reply with DocumentHighlights.
Edit: 563401c mitigates this in emacs, by overwriting some lsp-mode functions when cquery is enabled. This works, and should work with non-cquery aware tools too (tested with lsp-ui). the vscode plugin has something similar, not sure about neovim though.
The text was updated successfully, but these errors were encountered:
It executes commands - its a common interface for sending custom commands to the server, custom commands like applying a codeaction or jumping to a specific kind of reference
Hi guys. I'm experiencing the same issue with the latest lsp-mode, lsp-ui and cquery. When I'm trying to apply Fixit Pick one of N includes to insert, it says
Error from the Language Server: Fail to parse ’workspace/executeCommand’ /params/comman, expected std::string (Invalid Parameters)
Or probably I'm missing something?
Thank you very much!
Sign up for freeto subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Currently
textDocument/codeAction
andtextDocument/codeLens
respond with commands consisting of textedits that should be applied by the client. however, they are supposed to respond with commands that can be sent back to the server usingworkspace/executeCommand
, and this is what at least lsp-mode does.To support code actions and code lenses correctly, we should respond to
workspace/executeCommand
. Doing so is simple, we can just quickly reply with a aworkspace/applyEdit
containing what is currently sent with the codeAction, and for code lenses, we would reply withDocumentHighlight
s.Edit: 563401c mitigates this in emacs, by overwriting some lsp-mode functions when cquery is enabled. This works, and should work with non-cquery aware tools too (tested with lsp-ui). the vscode plugin has something similar, not sure about neovim though.
The text was updated successfully, but these errors were encountered: