Open ghost opened 4 years ago
Any help will be welcomed. As the OP said, I am currently using Magic Racket plugin on VSCode which depends on this LSP. Since I am working on WSL2, my experience for Linux is quite limited, (I don't even know how to start X server on WSL2 to let this LSP run).
The package you are referring to is hosted at https://github.com/jeapostrophe/racket-langserver. This is racket-language-server
, a different implementation of the LSP.
(The Magic Racket VS Code extension uses the other LSP package.)
On linux, due to the (recursive) dependencies on gui-lib, racket-langserver cannot run without a running X11 server. I believe the responsible dependencies are, besides gui-lib itself, drracket-tools-lib, which can be easily refactored into a headless component for racket-langserver, based on my experimentation... and racket-doc, which cannot. Since I've never used racket I'm not entirely sure what that racket-doc is doing; maybe it's not so hard to fix that issue as well.
Anyways, here's what happens if you try without X installed:
With X installed but not running:
For completeness, with GTK installed and a non-X backend running there's also an error loading
libX11
.Since this info was surprising to some people: Yes, there's a point to running a language server on a headless server: not only for TUI text editors, but even for GUI ones like VS Code Remote. And for what it's worth, I've not run into any other language servers which require X.