taplo icon indicating copy to clipboard operation
taplo copied to clipboard

LSP does not work

Open inferiorhumanorgans opened this issue 1 year ago • 3 comments

Ran cargo install taplo-cli and waited for all three hundred five dependencies to download and compile.

Checked that helix found the taplo binary.

Checked that taplo lists an lsp subcommand.

No error messages are printed when the lsp subcommand is run.

No error messages are printed when the lsp command is run with --log-spans.

No error messages are printed when the lsp command is run with --verbose.

Finally when run with --log-spans and --verbose this little gem pops up:

the LSP is not part of this build, please consult the documentation about enabling the functionality

If the LSP is not included in this rather lengthy build, why is there an lsp command and why does it fail silently?

Welp, off to the docs which have no descriptive text.

inferiorhumanorgans avatar Jul 10 '23 03:07 inferiorhumanorgans

Some documentation might be missing here. The reference is probably more the website but the features are written at the end only.

I think there's a few options to solve this issue (PRs are welcome):

  • Make lsp a default feature. How often is taplo used without LSP?
  • Improve the documentation to mention that cargo install taplo-cli --features=lsp is the way to go.

ia0 avatar Jul 10 '23 09:07 ia0

Make lsp a default feature. How often is taplo used without LSP?

I'm fine with this, the schema handling (including HTTP-related code) is by far the most bloated part of the application, compared to that the LSP code is rather tiny, the separate lsp feature doesn't mean as much as it used to.

tamasfe avatar Jul 10 '23 18:07 tamasfe

@panekj Is it possible to make sure that the lsp version of taplo is available through npm for the next release as the default? It is a really bad situation currently, everyone wants the lsp but are forced to jump through hoops to get it causing confusion and wasted time. Cheers!

David-Else avatar Aug 30 '23 10:08 David-Else