Skip to content

Conversation

@micahscopes
Copy link
Collaborator

@micahscopes micahscopes commented Jan 12, 2025

These changes fix basic language server functionality on the salsa-update branch.

Changes

  • Ensure that debug / tracing level logs aren't spamming the LSP client. I tried with nvim and at one point it was accumulating at least 20MB/sec of log statements. The language server pegged at 100% CPU usage, this was seemingly related to the old tracing configuration.
    • Gnome even crashed a few times when I did :LspLog in nvim in zed.
  • The language server was logging some things to stderr and others to the LSP client... instead this directs all tracing output to the LSP client and filters out debug and trace levels by default.

@micahscopes
Copy link
Collaborator Author

By the way. If you want to use nvim to debug the language server (it's nice and quick) and you want to see the logs you'll need to do this:

  1. Add something like vim.lsp.set_log_level("INFO") to your nvim config
  2. Use :LspLog to see the logfile

@micahscopes micahscopes force-pushed the consolidate-tracing-setup branch from 42a356c to bea43e9 Compare January 12, 2025 05:36
@micahscopes
Copy link
Collaborator Author

This is included in #1033

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant