Track parent turns for nested Codex requests - #35835
Merged
copyberry[bot] merged 1 commit intoJul 28, 2026
Merged
Conversation
## What changed - Propagate the initiating turn ID through agent spawns, follow-up tasks, reviews, and delegated Codex sessions. - Add `parent_turn_id` to Responses client and turn metadata while keeping it out of external MCP metadata. - Preserve parent-turn provenance across queued agent messages when their triggering parent is unambiguous. ## Testing - Cover spawned, resumed, nested, reviewed, delegated, and WebSocket request metadata. - Verify queued messages do not claim ambiguous or queue-only parent turns. GitOrigin-RevId: 481fdebbe7df2031880fe259509273cce50b20a8
copyberry
Bot
force-pushed
the
copyberry/codex-internal-to-codex-oss/481fdebbe7df2031880fe259509273cce50b20a8
branch
from
July 28, 2026 21:59
a32f359 to
1def0a8
Compare
copyberry
Bot
deleted the
copyberry/codex-internal-to-codex-oss/481fdebbe7df2031880fe259509273cce50b20a8
branch
July 28, 2026 22:00
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 subscribe to this conversation on GitHub.
Already have an account?
Sign in.
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.
Track parent turns for nested Codex requests
What changed
parent_turn_idto Responses client and turn metadata while keeping it out of external MCP metadata.Testing