Skip to content

Commit 5aefe78

Browse files
committed
internal: Avoid newlines in fetch workspace errors
Most logs lines don't have newlines, ensure fetch workspace errors follow this pattern. Before: 2024-08-28T21:11:58.431856Z ERROR FetchWorkspaceError: rust-analyzer failed to discover workspace After: 2024-08-28T21:11:58.431856Z ERROR FetchWorkspaceError: rust-analyzer failed to discover workspace
1 parent 199c01d commit 5aefe78

File tree

1 file changed

+2
-2
lines changed
  • src/tools/rust-analyzer/crates/rust-analyzer/src

1 file changed

+2
-2
lines changed

src/tools/rust-analyzer/crates/rust-analyzer/src/main_loop.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -689,7 +689,7 @@ impl GlobalState {
689689
self.fetch_workspaces_queue
690690
.op_completed(Some((workspaces, force_reload_crate_graph)));
691691
if let Err(e) = self.fetch_workspace_error() {
692-
error!("FetchWorkspaceError:\n{e}");
692+
error!("FetchWorkspaceError: {e}");
693693
}
694694
self.wants_to_switch = Some("fetched workspace".to_owned());
695695
(Progress::End, None)
@@ -729,7 +729,7 @@ impl GlobalState {
729729
BuildDataProgress::End(build_data_result) => {
730730
self.fetch_build_data_queue.op_completed(build_data_result);
731731
if let Err(e) = self.fetch_build_data_error() {
732-
error!("FetchBuildDataError:\n{e}");
732+
error!("FetchBuildDataError: {e}");
733733
}
734734

735735
if self.wants_to_switch.is_none() {

0 commit comments

Comments
 (0)