Show strict review warnings in the TUI (#39635)

## What changed

- Render `StrictReviewRequired` notifications as warning history cells that explain tool calls may take extra time.
- Preserve the active command and task-running state when the notification arrives.

## Testing

- Add a TUI snapshot test covering the warning and continued command output.

GitOrigin-RevId: bf01b612a22b537b247b6df6818080fc73b5414d
This commit is contained in:
Dylan Hurd authored and copyberry committed 2026-08-20 07:17:31 +00:00
1 parent 7ea7b29369
commit 7edd0a4c9d
3 files changed
+48 -1

No files matched your search

+9 -1
View File
@@ -161,6 +161,15 @@ impl ChatWidget {
self.on_warning(notification.message);
}
}
ServerNotification::StrictReviewRequired(_) => {
self.app_event_tx.send(AppEvent::InsertHistoryCell(Box::new(
history_cell::new_warning_event(
"This request requires additional safety checks, some tool calls might take extra time"
.to_string(),
),
)));
self.request_redraw();
}
ServerNotification::DeprecationNotice(notification) => {
self.on_deprecation_notice(notification.summary, notification.details)
}
@@ -208,7 +217,6 @@ impl ChatWidget {
| ServerNotification::ThreadArchived(_)
| ServerNotification::ThreadDeleted(_)
| ServerNotification::ThreadUnarchived(_)
| ServerNotification::StrictReviewRequired(_)
| ServerNotification::RawResponseItemCompleted(_)
| ServerNotification::RawResponseCompleted(_)
| ServerNotification::CommandExecOutputDelta(_)