Skip to content

Clear live hook rows when turns finalize#20674

Merged
abhinav-oai merged 1 commit into
mainfrom
abhinav/clear-live-hooks-on-turn-finalize
May 1, 2026
Merged

Clear live hook rows when turns finalize#20674
abhinav-oai merged 1 commit into
mainfrom
abhinav/clear-live-hooks-on-turn-finalize

Conversation

@abhinav-oai

Copy link
Copy Markdown
Collaborator

Why

When a user interrupts a turn while a hook is still running, the normal turn status is cleared but the separate live hook row can remain visible as Running because the TUI may never receive a matching HookCompleted event before cancellation. Once the turn itself is finalized, that turn-scoped live state should not remain on screen.

What

  • clear any still-live active_hook_cell during turn finalization
  • add a regression snapshot covering an interrupted turn with a visible PreToolUse hook row

Testing

  • cargo test -p codex-tui interrupted_turn_clears_visible_running_hook
  • attempted cargo test -p codex-tui (currently aborts on unrelated existing stack overflow in app::tests::discard_side_thread_removes_agent_navigation_entry)

@abhinav-oai abhinav-oai marked this pull request as ready for review May 1, 2026 20:03
@abhinav-oai abhinav-oai enabled auto-merge (squash) May 1, 2026 20:41
@abhinav-oai abhinav-oai merged commit d554794 into main May 1, 2026
25 checks passed
@abhinav-oai abhinav-oai deleted the abhinav/clear-live-hooks-on-turn-finalize branch May 1, 2026 21:48
@github-actions github-actions Bot locked and limited conversation to collaborators May 1, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants