Open siegel opened 2 years ago
Hmm, good to know! This looks like it might be a fair amount of work to implement correctly / without impacting runtime performance. PR welcome, if not I'll get around to this eventually... For anyone interested in chipping in, this represents a bug for clients that don't support WorkspaceEdits
.
I'm working on Code Action support for an upcoming BBEdit feature update, and a beta tester found a bug, as follows:
When BBEdit sends a
textDocument/codeAction
request to the server, it's responding with workspace edits, even though the client did not ever advertise support for same — and in fact even if the client explicitly reports that it does not support workspace edits.For example, in response to this request:
The server responds with:
This would be correct if BBEdit had advertised that it implements workspace edits (
workspace.workspaceEdit
), but it does not advertise that at all, in which case Jedi should have supplied something like:I think I have a functioning workaround, but it would be more compatible if Jedi paid attention to whether the client capabilities included a
workspace.workspaceEdit
dictionary, and provided a suitably formed response either way.