Code at the speed of thought – Zed is a high-performance, multiplayer code editor from the creators of Atom and Tree-sitter.
Silence error log when deserializing agent panel navigation history (#30011)
Cole Miller1a80103eaf9d
diff --git a/crates/agent/src/history_store.rs b/crates/agent/src/history_store.rsindex 688f9557a99..c2018e1c3ba 100644--- a/crates/agent/src/history_store.rs+++ b/crates/agent/src/history_store.rs@@ -97,9 +97,10 @@ impl HistoryStore {let contents = cx.background_spawn(async move { std::fs::read_to_string(path) }).await- .context("reading persisted agent panel navigation history")?;+ .ok()?;let entries = serde_json::from_str::<Vec<SerializedRecentEntry>>(&contents)- .context("deserializing persisted agent panel navigation history")?+ .context("deserializing persisted agent panel navigation history")+ .log_err()?.into_iter().take(MAX_RECENTLY_OPENED_ENTRIES).map(|serialized| match serialized {@@ -134,10 +135,10 @@ impl HistoryStore {}).ok();- anyhow::Ok(())+ Some(())}})- .detach_and_log_err(cx);+ .detach();Self {thread_store,