Skip to content

Comments

ensure stop button comes back#292366

Merged
meganrogge merged 1 commit intomainfrom
fix-button
Feb 3, 2026
Merged

ensure stop button comes back#292366
meganrogge merged 1 commit intomainfrom
fix-button

Conversation

@meganrogge
Copy link
Collaborator

@meganrogge meganrogge commented Feb 2, 2026

fixes #283328

stop-button.mov

When clicking "Focus Terminal", the elicitation was immediately hidden and its state set to Accepted. This caused requestInProgress to become false and never recover, so the stop button disappeared permanently.

Now, when the callback returns a Symbol (like focusTerminalSelection, we return ElicitationState.Pending instead of hiding the elicitation immediately. The elicitation gets properly hidden later when the user provides input in the terminal, at which point requestInProgress correctly returns to true and the stop button reappears.

cc @Tyriar

@meganrogge meganrogge self-assigned this Feb 2, 2026
@meganrogge meganrogge added this to the February 2026 milestone Feb 2, 2026
@meganrogge meganrogge enabled auto-merge (squash) February 2, 2026 18:53
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This change adjusts how terminal-input chat elicitations are handled so that the “stop” button correctly reappears after the user focuses the terminal and provides input, instead of disappearing permanently.

Changes:

  • Update _createElicitationPart’s accept and reject handlers to treat a symbol return value (e.g. focusTerminalSelection) as a signal to keep the elicitation in a Pending state and visible.
  • Defer hiding the ChatElicitationRequestPart and clearing _promptPart until after the symbol case is resolved (e.g. once terminal input is received), returning ElicitationState.Pending in that interim state.
  • Preserve existing behavior (hide + Accepted/Rejected) for all non-symbol return values from onAccept/onReject.

@meganrogge meganrogge merged commit 53d2889 into main Feb 3, 2026
27 of 28 checks passed
@meganrogge meganrogge deleted the fix-button branch February 3, 2026 05:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

No stop button to interrupt agent

2 participants