Suppress duplicate compaction and terminal wait events (#17601)

Addresses #17514

Problem: PR #16966 made the TUI render the deprecated context-compaction
notification, while v2 could also receive legacy unified-exec
interaction items alongside terminal-interaction notifications, causing
duplicate "Context compacted" and "Waited for background terminal"
messages.

Solution: Suppress deprecated context-compaction notifications and
legacy unified-exec interaction command items from the app-server v2
projection, and render canonical context-compaction items through the
existing TUI info-event path.
This commit is contained in:
Eric Traut
2026-04-13 08:59:19 -07:00
committed by GitHub
Unverified
parent 370be363f1
commit 7c797c6544
2 changed files with 29 additions and 1 deletions
+2 -1
View File
@@ -2193,6 +2193,7 @@ impl ChatWidget {
self.request_redraw();
}
#[cfg(test)]
fn on_agent_message(&mut self, message: String) {
self.finalize_completed_assistant_message(Some(&message));
}
@@ -5924,7 +5925,7 @@ impl ChatWidget {
self.exit_review_mode_after_item();
}
ThreadItem::ContextCompaction { .. } => {
self.on_agent_message("Context compacted".to_owned());
self.on_context_compacted();
}
ThreadItem::HookPrompt { .. } => {}
ThreadItem::CollabAgentToolCall {