Merge remote-tracking branch 'upstream/dev/friel/tui-watchdog-and-subagent-behavior' into tui-watchdog-timer-countdown

# Conflicts:
#	codex-rs/tui/src/chatwidget/tests/app_server.rs
This commit is contained in:
Friel
2026-04-02 07:53:22 +00:00
2 changed files with 7 additions and 1 deletions
+6
View File
@@ -935,6 +935,7 @@ impl SubagentRegistry {
.retain(|thread_id, _| !superseded.contains(thread_id));
}
#[cfg_attr(not(test), allow(dead_code))]
fn on_close_end(&mut self, event: &CollabCloseEndEvent) -> Option<Box<dyn HistoryCell>> {
let receiver_id = event.receiver_thread_id;
let info = self.agents.get_mut(&receiver_id)?;
@@ -953,6 +954,7 @@ impl SubagentRegistry {
None
}
#[cfg_attr(not(test), allow(dead_code))]
fn on_wait_end(&mut self, event: &CollabWaitingEndEvent) {
for (thread_id, status) in &event.statuses {
let Some(info) = self.agents.get_mut(thread_id) else {
@@ -1169,6 +1171,7 @@ impl SubagentRegistry {
}
}
#[cfg_attr(not(test), allow(dead_code))]
fn is_terminal_status(status: &AgentStatus) -> bool {
matches!(
status,
@@ -1179,6 +1182,7 @@ fn is_terminal_status(status: &AgentStatus) -> bool {
)
}
#[cfg_attr(not(test), allow(dead_code))]
fn terminal_summary(status: &AgentStatus) -> String {
match status {
AgentStatus::Completed(Some(message)) => {
@@ -2169,6 +2173,7 @@ impl App {
self.primary_thread_id.is_some() && self.active_thread_id == self.primary_thread_id
}
#[cfg_attr(not(test), allow(dead_code))]
fn emit_or_queue_subagent_history(&mut self, cell: Box<dyn HistoryCell>) {
if self.subagents_root_active() {
self.app_event_tx.send(AppEvent::InsertHistoryCell(cell));
@@ -2215,6 +2220,7 @@ impl App {
self.update_subagent_animation(root_active);
}
#[cfg_attr(not(test), allow(dead_code))]
fn process_subagent_side_effects(&mut self, thread_id: ThreadId, event: &Event) {
if self.primary_thread_id == Some(thread_id) {
self.subagents.set_root_thread(thread_id);
@@ -28,7 +28,7 @@ async fn collab_spawn_end_shows_requested_model_and_effort() {
prompt: "Explore the repo".to_string(),
model: "gpt-5".to_string(),
reasoning_effort: ReasoningEffortConfig::High,
spawn_mode: codex_protocol::protocol::AgentSpawnMode::Spawn,
spawn_mode: AgentSpawnMode::Spawn,
status: AgentStatus::PendingInit,
}),
});