mirror of
https://github.com/zed-industries/zed.git
synced 2025-02-10 04:09:37 +00:00
6780e80bf7
r-a now has 2 different types of diagnostics: * "disk-based" ones that come from `cargo check` and related, that emit `project::Event::DiskBasedDiagnosticsStarted` and `DiskBasedDiagnosticsFinished` * "flycheck" diagnostics from r-a itself, that it tries to dynamically apply to every buffer open, that come with `DiagnosticsUpdated` event. Latter diagnostics update frequently, on every file close and open, but `diagnostics.rs` logic had never polled for new diagnostics after registering the `DiagnosticsUpdated` event, so the only way we could have newer diagnostics was to re-open the whole panel. The PR fixes that, and also adds more debug logging to the module. The logic of the fix looks very familiar to previous related fix: https://github.com/zed-industries/zed/pull/3128 One notable thing after the fix: "flycheck" diagnostics stay forever if the diagnostics panel is opened: excerpts in that panel do not allow the buffer to get dropped (hence, closed in terms of r-a) and get the updated, zero diagnostics. If the diagnostics panel is opened and closed multiple times, those errors gradually disappear. Release Notes: - Fixed diagnostics panel not refreshing its contents properly |
||
---|---|---|
.. | ||
src | ||
Cargo.toml |