I’m not really sure how to diagnose this. Is there a way I can log all the requests and notifications that Nova receives from a LSP, so that I could begin to determine if the workspace/applyEdit request is coming in the expected format?
Is there some kind of extra logging I can enable within Nova when it can’t process LSP requests?
This seems to include two conflicting fixes: one for adding a suggested import, one for adding an empty function declaration. But maybe that’s okay? Will keep digging but would love someone with insight into how code actions are resolved to take a look.
Don’t know if this needs to be said, but this issue isn’t confined to the Deno language server. Rust Analyzer also only provides documentChanges, and Code Actions are failing to execute. It’s a real shame, as RA has some incredibly handy Code Actions.
This is starting to drive me crazy (and back to Sublime).
@logan If Nova doesn’t support documentChanges in WorkspaceEdits, then it should be setting WorkspaceEditClientCapabilities.documentChanges to false(docs) if my reading of the spec is correct.
From WorkspaceEdit link above:
If a client doesn’t support documentChanges or workspace.workspaceEdit.resourceOperations, then only plain TextEdits using the changes property are supported.
Currently, Nova sets this capability to true in its initialize message to language servers (2nd to last setting pasted below):