Skip to content
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

Tracking lsp spec compliance (from version 3.3) #134

Closed
27 of 35 tasks
lukel97 opened this issue Aug 28, 2018 · 20 comments
Closed
27 of 35 tasks

Tracking lsp spec compliance (from version 3.3) #134

lukel97 opened this issue Aug 28, 2018 · 20 comments

Comments

@lukel97
Copy link
Collaborator

lukel97 commented Aug 28, 2018

EDITED by @jneira: we are gonna put here the main checklist of features to give it more visibility

3.3

3.11

  • Add support for CodeActionOptions to allow a server to provide a list of code action it supports.

3.12

  • Add support for textDocument/prepareRename request.

3.13

  • File and folder operations (create, rename, move) to workspace edits.

3.14

  • Signature label offsets.
  • Location links.
  • textDocument/declaration request.

3.15

  • generic progress reporting.
  • specific work done progress reporting support to requests where applicable.
  • specific partial result progress support to requests where applicable.
  • textDocument/selectionRange.
  • server and client information.
  • signature help context.
  • add version on PublishDiagnosticsParams
  • CodeAction#isPreferred.
  • CompletionItem#tag.
  • Diagnostic#tag.
  • Add DocumentLink#tooltip support.
  • Add trimTrailingWhitespace, insertFinalNewline and trimFinalNewlines to FormattingOptions.
  • Add support for context in SignatureHelpRequest (noted by @bubba in Add support for context in SignatureHelpRequest #190)

3.16

@theobat

This comment has been minimized.

alanz added a commit that referenced this issue Apr 16, 2019
And deprecate the old MarkedString as per the LSP spec.

Closes #141

Addresses some of #134
@EggBaconAndSpam
Copy link

I would love support for this one in particular:

3.13

* [ ]   Add support for file and folder operations (create, rename, move) to workspace edits.

@lukel97
Copy link
Collaborator Author

lukel97 commented Jun 13, 2019

@EggBaconAndSpam I believe we are yet to add workspace support first. I think we have the types defined, but yes this would be a great feature to have! It might be nice to have a separate issue for this since there’s probably a lot of discussion needed around how the VFS/api will work around it, assuming that we’re adding deeper integration than just handlers.

@EggBaconAndSpam
Copy link

My use-case is the following: I would like to be able to create files via the "workspace/applyEdit" command; as far as I understand it workspaces as a concept are largely orthogonal to this feature. Currently the corresponding haskell-lsp-types definition only covers edits to existing files:

(From WorkspaceEdit.hs)

data WorkspaceEdit =
  WorkspaceEdit
    { _changes         :: Maybe WorkspaceEditMap
    , _documentChanges :: Maybe (List TextDocumentEdit)
    } deriving (Show, Read, Eq)

Which corresponds to documentChanges?: TextDocumentEdit[];, while the new spec extends this to documentChanges?: (TextDocumentEdit[] | (TextDocumentEdit | CreateFile | RenameFile | DeleteFile)[]);. I propose something along these lines:

data DocumentChange = DCEdit TextDocumentEdit
                    | DCCreate CreateFile
                    | DCRename RenameFile
                    | DCDelete DeleteFile


data WorkspaceEdit =
  WorkspaceEdit
    { _changes         :: Maybe WorkspaceEditMap
    , _documentChanges :: Maybe (List DocumentChange)
    } deriving (Show, Read, Eq)

@thomasjm
Copy link
Collaborator

I just made a pair of PRs for 3.11 and 3.12 support. They're not really adequately tested yet but hopefully this is a step in the right direction.

@jneira jneira changed the title Add 3.11 and 3.12 support Add support to lsp spec 3.3 -> 3.15 Feb 20, 2020
@jneira

This comment has been minimized.

@jneira jneira changed the title Add support to lsp spec 3.3 -> 3.15 Add support to lsp spec 3.3 -> 3.16 May 25, 2020
@jneira jneira changed the title Add support to lsp spec 3.3 -> 3.16 Tracking lsp spec compliance (from version 3.3) May 25, 2020
@jneira jneira pinned this issue May 25, 2020
@michaelpj
Copy link
Collaborator

Support for changeAnnotations and AnnotatedTextEdit would be nice.

@michaelpj
Copy link
Collaborator

#290 should fix the last remaining place that needs MarkupContent, and one other minor 3.16 addition to SignatureInformation.

@michaelpj
Copy link
Collaborator

I was having a look and it looks like lots of things in the list are done, sadly I can't check the checkboxes.

@jneira
Copy link
Member

jneira commented Feb 27, 2021

@michaelpj i suspected most of them was done too, what about copy it in a new comment and check what do you know about? I did that in #134 (comment)

@michaelpj
Copy link
Collaborator

I think it's almost all done! As far as I can see it's only some 3.16 things that are missing. Note that this is based on going through @jneira 's list not the full LSP changelog.

The remaining items are two substantial ones and one easy one:

@michaelpj
Copy link
Collaborator

Oh, other things we're missing from 3.16:

  • Monikers
  • Linked editing
  • Change annotations
  • Locale
  • Diagnostic data
  • MessageActionItem additional properties
  • create/rename/delete notifications
  • normalizesLineEndings

@jneira
Copy link
Member

jneira commented Jun 22, 2021

We have semantic tokens support and call hierarchy!

@pranaysashank
Copy link

Since 3.16, there are new number types https://microsoft.github.io/language-server-protocol/specifications/specification-current/#number . We may want to provide newtype wrappers for them as using Int may lead to subtle bugs like haskell/haskell-language-server#2169

@michaelpj
Copy link
Collaborator

I'm going to try and update the checklist in the original description and remove the others!

@jneira
Copy link
Member

jneira commented Nov 2, 2021

I wonder if this list should be also placed in docs for reference, in the README?

@michaelpj
Copy link
Collaborator

I think if we were going to do that we'd want to actually list all the things we've implemented, which would be a bit tedious. I think it might be good to say which versions we have completely supported and which ones are partial, though.

@michaelpj
Copy link
Collaborator

Okay, main checklist should be up-to-date. I think we're actually doing pretty well: we're missing a few things from 3.16, but that's it.

@pepeiborra pepeiborra unpinned this issue Dec 15, 2021
@joyfulmantis
Copy link
Collaborator

We are also missing codeAction/resolve, which is new in 3.16. This is a blocker for implementing haskell/haskell-language-server#3534

@michaelpj
Copy link
Collaborator

We're generating the code from the metamodel now, so we should have full compliance with 3.17.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

8 participants