Require confirmation for safety-buffered retries (#42380)

## What changed

- Show a confirmation before stopping a safety-buffered attempt and retrying
  with the server-selected faster model.
- Explain that the retry starts a new thread, preserves actions already taken,
  and may use a less capable model; allow the user to keep waiting instead.
- Dismiss the buffering or confirmation view when the response starts or the
  turn is no longer eligible for retry.
- Refresh the buffering copy and wrap confirmation text correctly in narrow
  terminals.

## Testing

- Cover retry confirmation, cancellation, turn completion, response startup,
  stale updates, and narrow-terminal rendering.

GitOrigin-RevId: 013bc47174811dd104b421774577c2808c732bfa
This commit is contained in:
Eric Traut authored and copyberry committed 2026-09-02 22:49:48 +00:00
1 parent 69cebb5d15
commit 0588fc941c
12 files changed
+287 -34

No files matched your search

+10
View File
@@ -770,6 +770,16 @@ impl App {
tracing::error!(error = ?err, "failed to start turn through app server");
}
}
AppEvent::ConfirmSafetyBufferedRetry {
thread_id,
turn_id,
model,
turn,
prompt,
} => {
self.chat_widget
.confirm_safety_buffered_retry(thread_id, turn_id, model, turn, prompt);
}
AppEvent::RetrySafetyBufferedTurn {
thread_id,
turn_id,