Repository navigation
fix: an outside agent's message that never ran no longer reaches a later agent - #997
Merged
Merged
Conversation
…ter agent When an outside agent's turn was accepted but never reached the agent (the reactor's last ceiling check refused it, its start failed before the provider took it, Stop landed while it was prepared, or a restart cut it off while starting), the message stayed in the chat unmarked. Hand-off seeds, fork context and room catch-up notes then gave its text to later agents, possibly ones with more access. The reactor now sends one server-only command for every message no one can send again, `thread.message.not-run` (renamed from `thread.lead-pass.not-run`). A pass keeps its note and line; an outside message is marked with `thread.continue-at-reset-skipped`, which every client already reads as "never reached the agent", so no client meets a new event. The mark lands before the failure is reported. A restart's note marks an outside message whose turn never began. The chat shows "Not sent" under it, and the outside agent's thread_wait answers taken_back for it.
- A restart marks an outside message it finds still starting before it settles the session, in the reactor, not in the later restart-continue decision that lived only in memory: a startup that dies in between marks it again on the next one. - ProviderService.sendTurn no longer fails after the provider took the turn: the bookkeeping after it (latency record, directory write, analytics) logs instead. A failure there made a running turn read as one that never started, and would have marked a message the agent read as not sent. - Documents the remaining gap: a restart between Claude reporting a turn started and its prompt reaching the program.
|
The latest updates on your projects. Learn more about Vercel for GitHub. 1 Skipped Deployment
|
This branch was previously deployed
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.
When an outside agent's message was accepted but never reached the agent, it stayed in the chat looking like a normal message. That happened when the access check refused it at the last moment, its start failed, Stop landed while it was being prepared, or a restart cut it off while starting. Hand-off history, a fork's context and a room's catch-up note then gave its text to later agents, which can run with more access than the outside agent was allowed.
Now every one of those paths marks the message "not sent", so no history carries it:
thread.message.not-run(renamed fromthread.lead-pass.not-run). A lead chat's pass keeps its note and line. An outside agent's message is marked withthread.continue-at-reset-skipped, an event every client already reads as "never reached the agent", so no released client meets a new event or value.ProviderService.sendTurnno longer fails after the provider took the turn. A failed bookkeeping write there used to make a running turn read as one that never started.thread_waitanswerstaken_back, andthread_readlabels it.Known gap: Claude reports a turn started a moment before its prompt is queued and written to the program. A restart in that window leaves the message unmarked.