Find less-obtrusive way to surface LSP error
Check for existing issues
- [X] Completed
Describe the bug / provide steps to reproduce it
From Nathan:
We need a better plan than dumping a notification to the screen. not sure what we should do, but whatever this is trying to avoid it's making it twice as bad by cluttering the experience.
Slack thread link: here
Zed Version and System Specs
Zed: v0.170.0 (Zed Nightly 93f117b21a07cb0e5c41682658339a473794d2da) OS: macOS 15.1.1 Memory: 64 GiB Architecture: aarch64
If applicable, add screenshots or screencasts of the incorrect state / behavior
If applicable, attach your Zed.log file to this issue.
Zed.log
I agree that something better should be done with these notifications, the alternative would require some UI design. It should let the user know that an error occurred without obscuring any content they might be interacting with. Thoughts on a couple options:
-
Add them to the notifications pane, have a dot appear when there are unread notifications. Maybe have the notifications pane button flash when something happens? For setups that often generate notifications it may be perpetually unread and so the dot becomes uninformational.
-
Add them to the notifications pane and display in the bottom bar for a while? This space is already pretty overloaded, though.
For LSP specifically, these are shown when the LSP sends us ShowMessageRequest (handler here. These are also shown when a request for mutation fails (formatting, completions, code actions, rename).
For the specific internal message in the screenshot, with the help of looking at code that @SomeoneToIgnore found in rust-analyzer, I figured out it's because we were using rust-analyzer built from source with my patch to improve SCIP symbols which we were using with refactor.
Hi there! 👋 We're working to clean up our issue tracker by closing older issues that might not be relevant anymore. If you are able to reproduce this issue in the latest version of Zed, please let us know by commenting on this issue, and we will keep it open. If you can't reproduce it, feel free to close the issue yourself. Otherwise, we'll close it in 7 days. Thanks for your help!
This issue was closed due to inactivity. If you're still experiencing this problem, please open a new issue with a link to this issue.
For the context, the work is happening to bring in something like
into Zed, and that error should go there.
This is mainly done: language servers can still send messages that we will show in the toast, but other errors we now show in the LSP button's menu and the activity indicator.