Repository navigation
fix: recheck browser cancellation after approval callbacks - #4322
marcuswood-oai wants to merge 1 commit into
Conversation
Codex Review Summary: ✅ CompletedThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
markstuart-oai
left a comment
There was a problem hiding this comment.
Both browser toolsets now recheck cancellation after the approval callback and before the next driver call. The new cases cover cancellation before an approved read or action in both toolsets.
Static review only. Hosted checks were still running.
There was a problem hiding this comment.
Reviewed the full change and surrounding sync/async dispatch, diagnostic observer, cancellation, and lifecycle paths, including an independent review. No actionable findings. The added checks stop approved reads before browser state access and stop actions before handler invocation when the approval diagnostic callback requests cancellation; cancellation propagation and lifecycle cleanup remain intact. The regression cases cover both paths in both toolsets.
Static review only; no candidate code or local tests executed. Hosted CI at review time: 13 successful checks, 9 skipped, and 4 still running; no failures observed.
Hosted CI update (2026-11-24 00:38 UTC): all checks are terminal, with 17 successful and 9 skipped; no failures.
Changes being requested
Recheck cancellation after the approval diagnostic callback returns, before reading browser state for an approved read or invoking a browser action. Apply the same checks to the sync and async toolsets.
Additional context & links
Four regression cases verify that cancellation from the callback prevents the next driver call. All four failed before the change. All 753 browser tests passed with the change. Ruff and ty passed for the changed files.