eclipse-lsp4e / eclipse-lsp4e/lsp4e

Provide an advanced LSP console

Open
#745 2 comments 2 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

enhancement
Dominant language
Java
Stars
85
Forks
69
Avg merge
8h 33m
Merged PRs (30d)
6

Description

I had started an issue at https://github.com/eclipse/lsp4e/issues/631 but I create a new one which is focus on LSP console.

I would like to try to convince you that a robust LSP console is really important to have.

I spend so many time to work on LSP console developement for IJ and it help us a lot. You can see the status of the server when it is starting, started, stopping,stopped or crash, see the pid, see the LSP messages, etc

Here a little demo which show the language servers which are available and you can see the status of each language server (when it is starting etc). The demo shows the LSP request / response received when the LSP hover is processed:

LSPConsoleInIJ

The LSP console shows:

  • the language servers which are available
  • the status of each server. You can pause (stop the process) or stop (disable the language server) with menu context
    image
  • the pid of the language server
  • you can copy/paste the command which starts the language server
  • the LSP request / response messages are formatted correctly and there is folding
    image
  • there is a search field:
    image

I know it is a long task, but IMHO LSP4E should provide this kind of LSP console which are very helpfull for 3 profiles:

  • the LSP4E developer who develop LSP client. You will understand more what it happens and you should discover some bugs that you have not though. In my case I have ported LSP4E on IJ and I discover some bugs where the server was restarted although it should not (ex : when I closed a workspace). It will be very helpfull to implement new features like cancel support; You could check with the search field that $cancel request will be send correctly for instance. The current console is very hard to use it, since the LSP messages is not formatted. The LSP message format should follow the spec and have the same format than vscode.

  • the LSP language server developer: when you develop a language server, you need to understand which data you send and check that you don't send too many response and when there is a bug, LSP console is your friend, you understand more what it happens.

  • the Users who use a language server: we spend so many time to assist user with problems and spend so many times to explain the process "please activate your log with this settings etc". With LSP console you don't need to explain that for assisting user, with LSP console it is very easy to have an overview (the server is started? the LSP messages appears correctly?).

  • the Copy Start command can help if the language server cannot be started:

image

A good sample of issue which is a nightmare is https://github.com/jbosstools/jbosstools-quarkus/issues/235

java.util.concurrent.ExecutionException: org.eclipse.lsp4j.jsonrpc.JsonRpcException: java.io.IOException: Stream closed at java.base/java.util.concurrent.CompletableFuture.reportGet(CompletableFuture.java:396) at

We don't know if the problem comes from the start command or if the language server can be started, but fails after. We have no overview of what it happens.

I know it is a long task to implement this kind of LSP console, but IMHO it is a requirement for LSP client developpers, LSP server developers and Users.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by examining the existing LSP console and the issue's examples of language-server status, PIDs, start commands, formatted messages, folding, and search. Define the scope and design with maintainers before implementation; done would require an agreed console covering the requested diagnostics and controls.

Written by the indexing model from the issue text.

Assessment

Tech stack
java
Domain
devtools
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.