about summary refs log tree commit diff
diff options
context:
space:
mode:
-rw-r--r--crates/rust-analyzer/src/config.rs7
-rw-r--r--crates/rust-analyzer/src/global_state.rs2
-rw-r--r--crates/rust-analyzer/src/main_loop.rs2
3 files changed, 8 insertions, 3 deletions
diff --git a/crates/rust-analyzer/src/config.rs b/crates/rust-analyzer/src/config.rs
index 833ee31eed8..ad1f9c40e2b 100644
--- a/crates/rust-analyzer/src/config.rs
+++ b/crates/rust-analyzer/src/config.rs
@@ -584,7 +584,12 @@ impl Config {
                 scope,
             ) {
                 Some(snippet) => self.snippets.push(snippet),
-                None => tracing::info!("Invalid snippet {}", name),
+                None => errors.push((
+                    format!("snippet {name} is invalid"),
+                    <serde_json::Error as serde::de::Error>::custom(
+                        "snippet path is invalid or triggers are missing",
+                    ),
+                )),
             }
         }
 
diff --git a/crates/rust-analyzer/src/global_state.rs b/crates/rust-analyzer/src/global_state.rs
index cfbd5f63bc1..ebd6f35b424 100644
--- a/crates/rust-analyzer/src/global_state.rs
+++ b/crates/rust-analyzer/src/global_state.rs
@@ -290,7 +290,7 @@ impl GlobalState {
             }
 
             let duration = start.elapsed();
-            tracing::info!("handled {} - ({}) in {:0.2?}", method, response.id, duration);
+            tracing::debug!("handled {} - ({}) in {:0.2?}", method, response.id, duration);
             self.send(response.into());
         }
     }
diff --git a/crates/rust-analyzer/src/main_loop.rs b/crates/rust-analyzer/src/main_loop.rs
index 96f4e2a50b9..3870161826b 100644
--- a/crates/rust-analyzer/src/main_loop.rs
+++ b/crates/rust-analyzer/src/main_loop.rs
@@ -314,7 +314,7 @@ impl GlobalState {
                             self.prime_caches_queue.op_completed(());
                             if cancelled {
                                 self.prime_caches_queue
-                                    .request_op("restart after cancelation".to_string());
+                                    .request_op("restart after cancellation".to_string());
                             }
                         }
                     };