ZIm/crates/language_tools/src
David Barsky 1af9f98c1d
lsp-log: Avoid trimming leading space in language server logs (#33418)
Not sure what the full intention/right fix for this is, but
https://github.com/zed-industries/zed/pull/32659 re-introduced trimming
of leading spaces. rust-analyzer has [a custom tracing
formatter](317542c1e4/crates/rust-analyzer/src/tracing/hprof.rs)
that is _super_ useful for profiling what the heck rust-analyzer is
doing. It makes prodigious use of whitespace to delineate to create a
tree-shaped structure. This change reintroduces the leading whitespace.

I made a previous change similar to this that removed a `stderr:` in
https://github.com/zed-industries/zed/pull/27213/. If this is a
direction y'all are happy to go with, I'd be happy to add a test for
this!

<details>
<summary>A screenshot of the before</summary>

<img width="1624" alt="Screenshot 2025-06-25 at 2 12 45 PM"
src="https://github.com/user-attachments/assets/a714d973-9377-41ca-8087-3b0e82b41620"
/>

</details>

<details>
<summary>A screenshot of the after</summary>

<img width="1136" alt="Screenshot 2025-06-25 at 2 40 07 PM"
src="https://github.com/user-attachments/assets/b798ca13-11fc-4f97-9602-55e782068a5a"
/>

</details>

cc: @mgsloan.

Release Notes:

- Fixed the removal of leading whitespace in a language server's stderr
logs.
2025-06-25 16:24:51 -06:00
..
key_context_view.rs Rename debug: commands to dev: (#30675) 2025-05-14 11:15:27 +02:00
language_tools.rs Add language server control tool into the status bar (#32490) 2025-06-25 19:57:28 +03:00
lsp_log.rs lsp-log: Avoid trimming leading space in language server logs (#33418) 2025-06-25 16:24:51 -06:00
lsp_log_tests.rs zlog: Replace usages of env_logger in tests with zlog (#31436) 2025-05-26 11:48:50 -04:00
lsp_tool.rs Add language server control tool into the status bar (#32490) 2025-06-25 19:57:28 +03:00
syntax_tree_view.rs debugger: Parse and highlight text with ANSI escape sequences (#32915) 2025-06-17 23:39:31 -04:00