Skip to content

April 2020 release: Language Server Support #528

Closed

Description

@dantleech

For the next #918 it would be great to bundle LSP support. There has been some significant progress.

Features (from spec):

  • Completion
  • Signature help
  • Goto Definition
  • Hover
  • Goto Type
  • Code Lens (not sure if WR will return the documentation prose)
  • Goto declaration (:warning: this is new functionality, but is possible with the WR Frame)
  • References (:warning: long blocking)
  • Implementations
  • Rename (:warning: long blocking)
  • ???

Indexing:

Improvements:

  • Language Server services should be started on initialized instead of initialize
  • Support progress notifications Language Server Workspace Query / Indexer #912
  • Combine extensions into packages, e.g. phpactor/reference-finder can also bundle the LSP extensions. will not do, see ADR.
  • Bundle Language Server by default

Other:

  • Performance / blocking (e.g. in class such as "product writer step")
  • Occasionally only methods completions are shown???
  • Server idles at around 10% CPU
  • Implement cancelRequest (or at least a stub for it)
  • implement "shutdown"
  • Completion too slow (classes) start at 3 chars?
  • Worse Reflection cache: caching is disabled for the LSP, but this slows down. implement a TTL cache. TTL Cache in Worse Reflection #929
  • Errors are not shown in CoC - why?
  • Function indexing (currently only classes are indexed)
  • Signature helper, active signature out of range, active parameter is null

Nice to have:

  • Refactor Language Server to use co-routines (return Proimises instead of Generators from handlers): this will also help prevent blocking with f.e.. completion.

Code Lens and Signature Help Example (intelliphense)

Untitled

Activity

  1. seagoj commented on Sep 13, 2018

    @seagoj

    I'd be interested in this. Particularly the ALE integration.

  2. dantleech commented on Dec 4, 2018

    @dantleech
    CollaboratorAuthor

    This is currently naively implemented by the language server extension (both over STDIN and TCP) but it can crash with prolonged use and it can only process one request at a time. Rewriting / refactoring it to process multiple requests would be the next step.

    ~/.vim/plugged/phpactor/bin/phpactor extension:install phpactor/language-server-extension
    

    Also, although it worked with the neovim_LanguageClient, it didn't seem to work with Ale.

  3. dantleech commented on Jan 20, 2019

    @dantleech
    CollaboratorAuthor

    Note further progress has been made, and the above extension / language server has been re-written. Currently supports completion, goto definition and hover (also theoretically signature completion).

    There are still some minor quirks and can only work on the develop branch.

  4. pinned this issue on Mar 29, 2020
  5. changed the title [-]LSP Support[/-] [+]April 2020 release: Language Server Support[/+] on Mar 29, 2020
  6. przepompownia commented on Mar 30, 2020

    @przepompownia
    Contributor

    Errors are not shown in CoC - why?

    How to reproduce it? I did not found any open issue with an example.

  7. dantleech commented on Mar 30, 2020

    @dantleech
    CollaboratorAuthor

    How to reproduce it?

    Error responses (handler not found for unsupported operations) are frequently returned from Phpactor (I've fixed some of the most frequent ones), but there is no indication of them in the client. Perhaps there is a setting in CoC.

  8. dantleech commented on May 3, 2020

    @dantleech
    CollaboratorAuthor

    Released

  9. unpinned this issue on May 3, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions