Repository navigation
Stop a finished call from keeping a thread busy forever - #200
Open
splitbrain-bot wants to merge 1 commit into
Open
splitbrain-bot wants to merge 1 commit into
splitbrain-bot wants to merge 1 commit into
Conversation
A thread stayed busy without end when a tool call was open and no final status came for it. The gateway opened a call on every tool call update that had no final status. The adapter also sends updates without any status for a call that is over, such as the exit of the terminal of a background command or the report of a PostToolUse hook. Such an update after the end of the turn opened the call again, and nothing closed it. The stop button then stayed in every browser until the next turn ended. An update without a status now opens no call. The return of the last prompt on a thread now ends the turn, which also closes a call that got no final status.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
A thread stayed busy without end: the stop button and the spinner stayed in every browser, also after a reload and on a device that opened the thread for the first time.
Cause:
Activitykeeps a thread speaking while a foreground tool call is open. It opened a call on everytool_call_updatethat had no final status. The Claude adapter also sends updates without any status for a call that is over, such as theterminal_exitof a background command or the report of a PostToolUse hook. Such an update after the end of the turn opened the call again. No final status followed, so the quiet timer started again everyAGENT_QUIET_SECONDSwithout end.Changes:
tool_call, or atool_call_updatewith a status that is not final, opens one.Limits:
AGENT_QUIET_SECONDS.Tests:
activity.test.tschecks that an update without a status does not open a finished call again, that it leaves an open call open, and that the end of the prompt ends a turn with an open call.upstream.test.tschecks that a prompt that returns ends a turn that left a tool call open, and that the browser is told.