You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Queued messages dropped under rapid back-to-back sends: ThreadLifecycleEventNotAppliedError (no transition for run.started from status active) #3716
When messages are sent to a thread in rapid succession (back-to-back threads.send calls with no settle wait between them), the server intermittently rejects a send with:
ThreadLifecycleEventNotAppliedError: no transition for run.started from status active
and the rejected message is dropped before delivery — it never reaches the agent and is not retained in the queue.
Reproduction (bb 0.43.1, desktop, macOS)
Have a thread whose previous turn has completed (run status active).
Send N messages back-to-back to that thread through threads.send (we drive this from a plugin RPC; a batch of ~50 sends reproduces it reliably).
Observed: roughly 2 of 3 unprotected batched runs die mid-sequence with the error above; in our logs the error appears 400+ times lifetime. Sending with mode queue does not avoid it.
The failing send is dropped pre-delivery. Subsequent sends continue.
Expected
A queued/rapid message should never be silently dropped. Either run.started from status active should be a legal transition, or the dispatch should wait for the run state instead of rejecting and discarding.
Workaround we currently ship
After a rejected send: settle-wait, then resend the same prompt (capped retries). With retry, batches complete 6/6 in our tests. Risk note: if a rejection can ever occur AFTER delivery, a resend would duplicate a turn — we found no such case; every observed failure was pre-delivery dispatch, but we cannot prove the invariant from outside.
Happy to provide more logs or a minimal script if useful.
Applied Bug · High priority · Medium effort; labels: threads, confirmed-repro.
REPRODUCED · high confidence. Concurrent sends pass idle admission together; competing start transactions then roll back without retaining the input. The regression reproduced this in two clean-base checkouts: four sends, one command, three lifecycle errors, zero queued messages.
The fix rechecks status inside the append transaction and reattempts dispatch. All 44 relevant tests and server typecheck pass; 73 changed lines across two files. PR is ready for review and has not been merged.
Activity
bb-slop-cop commentedon Sep 15, 2026
🚨 SLOP COP 🚨 ·
new-issue-autopilotApplied Bug · High priority · Medium effort; labels:
threads,confirmed-repro.REPRODUCED · high confidence. Concurrent sends pass idle admission together; competing start transactions then roll back without retaining the input. The regression reproduced this in two clean-base checkouts: four sends, one command, three lifecycle errors, zero queued messages.
Reproduction and root-cause report · Fix PR #3718
The fix rechecks status inside the append transaction and reattempts dispatch. All 44 relevant tests and server typecheck pass; 73 changed lines across two files. PR is ready for review and has not been merged.
Recheck thread status before committing dispatch (get-bb#3718)