Code at the speed of thought – Zed is a high-performance, multiplayer code editor from the creators of Atom and Tree-sitter.
Inline assistant: Clear failure text when regenerating (#44911)
Michael Benfieldfb574d88697a
diff --git a/crates/agent_ui/src/buffer_codegen.rs b/crates/agent_ui/src/buffer_codegen.rsindex d8d0efda0fb..25395278745 100644--- a/crates/agent_ui/src/buffer_codegen.rs+++ b/crates/agent_ui/src/buffer_codegen.rs@@ -409,6 +409,9 @@ impl CodegenAlternative {model: Arc<dyn LanguageModel>,cx: &mut Context<Self>,) -> Result<()> {+ // Clear the model explanation since the user has started a new generation.+ self.description = None;+if let Some(transformation_transaction_id) = self.transformation_transaction_id.take() {self.buffer.update(cx, |buffer, cx| {buffer.undo_transaction(transformation_transaction_id, cx);