Open lieryan opened 5 months ago
Ok, nevermind, I think I found the issue. It's because pylsp-rope is generating executeCommand with some non-standard arguments title
. I can fix that.
Other vim lsp clients seems to tolerate extra arguments there, but this isn't an LSP client issue.
Apologies for the noise.
Reopening this. Actually, apologies again for the noise, I was completely confused.
pylsp-rope was actually correct in emitting the title as required by LSP. There are two titles for the CodeAction.title
and the CodeAction.command.title
. Both are required attributes by the spec.
However, for some reason, title
is not a parameter for the workspace/executeCommand
. It seems that yegappan/lsp
is incorrectly passing off the title
into the executeCommand()
and pylsp
doesn't allow title
to be passed in.
I have committed 9111948aa541df98c66da57ab34e3f9914f44d01 to not send the title
field in the workspace/executeCommand requests. Note that this will not fully resolve the issue that you have raised. The Vim LSP channel support currently supports only numbers as identifiers
in LSP messages. But in this case, the language server uses a string (UUID) for the identifier. The Vim LSP channel support currently cannot handle this.
Hi, I was test driving the new lsp client, I had encountered a few problems with code action.
To reproduce:
Setup and activate virtualenv
Install python-lsp-server and a plugin with code action, for example, pylsp-rope:
Create this file:
Visually select the line and run
:LspCodeAction
Expected this to work and apply the code action change, but instead got this error message: