Repository navigation
Keep child completion output within its completed turn - #6822
Closed
bb-slop-cop[bot] wants to merge 1 commit into
Closed
bb-slop-cop[bot] wants to merge 1 commit into
bb-slop-cop[bot] wants to merge 1 commit into
Conversation
Collaborator
|
Closing in favour of #6821, which we're taking forward with follow-ups.
|
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.
🚨 SLOP COP 🚨 ·
new-issue-autopilotHuman comments
What was wrong
The parent-completion path looked up the latest non-empty output across the entire child thread. A completed turn without output therefore reused an earlier turn's result. Reproduced on trusted
origin/mainin two clean checkouts: https://get-bb.github.io/reports/issues/6820.htmlWhat changed
Carry the completed turn ID through the server notification follow-up and constrain its output lookup to that turn's root agent messages, including an empty last message. Preserve status-only completion notices with the existing no-output placeholder and preserve the thread-wide output route. This stays within the existing thread-completion notification/output subsystem; no public protocol, schema, dependency, stored-data, or CLI changes.
The patch changes 125 text lines: 120 additions + 5 deletions across 5 files (96 test lines and 29 production lines).
How you verified
/internal/session/eventsingestion and migrated SQLite: later empty-message and no-message turns must not reuse earlier output. Both fail on unchanged production code in two clean checkouts at916d684ac23d0b0de82c09cfc7553a50287d2188, then pass with this fix.pnpm exec turbo run test --filter=@bb/server -- test/internal/internal-events-tool-calls.test.ts -t 'does not reuse earlier child output': 2 passed after the fix.pnpm exec turbo run test --filter=@bb/server -- test/internal/internal-events-tool-calls.test.ts test/services/threads/child-thread-notifications.test.ts test/threads test/public/public-thread-data.test.ts: 714 passed across 48 files, including notification policy, batching, taxonomy, lifecycle, and existing output-route behavior.pnpm exec turbo run test --filter=@bb/db -- test/data/events.test.ts test/query-plans.test.ts: 145 passed.pnpm exec turbo run typecheck --filter=@bb/server --filter=@bb/db: passed. Scoped Turbo lint has no configured tasks; direct Oxlint on the five changed files passed. Formatting andgit diff --checkpassed; no binary changes.Fixes #6820