Repository navigation
fix(responses): handle Codex 0.164 request controls - #7473
Conversation
Codex 0.164 adds a positional configuration_update input item, a prompt_cache_key Omit/Custom policy, and a voice-session-id realtime header. - Strip configuration_update for Responses gateways OpenAI does not operate (passthrough and native compact replay); OpenAI-operated destinations keep it verbatim and in order. - Drop it explicitly in the translated parser and skip it in the agent-task tail walkers so a trailing update cannot hide the task. - Stop routed catalog rows inheriting supports_reasoning_effort_updates from GPT-6 templates, so Codex keeps effort on the request parameter. - Relay voice-session-id on live call-create and sideband join. - Pin prompt_cache_key SessionDerived/Custom/Omit across native, translated, cache-diagnostic, lineage and log-identity paths.
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info
📝 Walkthrough
Merge Risk: ⚪ Minimal · up to
|
|
✅ Deterministic PR hygiene checks passed. |
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
|
Merged with owner authority per maintainer decision 2026-10-21 (jun): the project owner authorized owner-path ( Exact-head verification on |
Summary
Codex 0.164 (openai/codex
816fa702..af91f6ef2c) changes three things on the request side. This PR makes opencodex handle each one.configuration_updateinput item (ResponseItem::ConfigurationUpdate,{type: "configuration_update", reasoning: {effort}}). This is a durable reasoning-effort control that the backend interprets at its position in history. Codex sends it whenever its provider identity isopenai, which loopback injection always satisfies, and only for catalog rows withsupports_reasoning_effort_updates.agent_messagealso hid the task from the encrypted-task guard and recovery, because both walkers stop at the first unrecognized tail item.api.openai.com) receive the item verbatim and in order. Other Responses gateways get the conversation without it, through a newCANONICAL_ONLY_INPUT_ITEM_TYPEStable applied in both the passthrough and the native/responses/compactgateway replay. The translated parser drops it without clearing pending reasoning. The tail walkers skip it the way they skipcompaction_trigger.normalizeRoutedCatalogEntryremovessupports_reasoning_effort_updatesfrom routed rows. Upstream declares that field#[serde(default)]and documents that missing metadata keeps effort changes on the ordinary request parameter. The native row and the exact Codex-forward alias keep it.prompt_cache_keypolicy (openai/codex#55587). Hosts can keep the session-derived key, send a Custom key, or Omit the field. Session and thread headers stay the same, and sub-agents inherit the policy. An audit found nothing broken: lineage cohorts, pool affinity, OAuth affinity and request-log conversation ids all key on thesession-id/thread-idheaders. Every adapter forwards the key only when the caller sent one. Cache diagnostics record an absent key aspresent: falseand only compare when both sides have one. New tests pin this end to end throughhandleResponses:voice-session-id(openai/codex#53784). This is the client voice session id, distinct from the realtimex-session-id. It is added toLIVE_CLIENT_PROTOCOL_HEADERS, so it is relayed on call-create and the sideband join only when the caller sent it.Provenance metadata (openai/codex#53831) needed no change. Upstream sends per-content
content_item_metadataonly foruse_responses_literows, insideinternal_chat_message_metadata_passthrough. Routed rows and pre‑5.6 natives already dropuse_responses_lite. Noncanonical Responses destinations already strip that whole block unlesspreserveResponsesMessageMetadatais set. The new gateway test asserts it with acontent_item_metadatapayload.sci/sci_plusare out of scope (covered by #7444).Verification
bun run typecheck: passbun run privacy:scan: passbun run structure:check: passbun test tests/responses/codex-0164-request-compat.test.ts(new, 9 cases),tests/server/server-live.test.ts,tests/codex-integration/codex-model-entitlements-program-shape.test.ts,tests/test-layout.test.ts,tests/test-layout-tooling.test.ts: passsrc/changes stashed, the gateway strip, tail-walker, live-header and routed-catalog cases fail. Theprompt_cache_keycases pass either way, as expected for regression pins on behavior that was already correct.bun run test:changed: 34309 pass / 42 skip / 0 fail (1530 files)bun run test: run under the machine lock. It reported two failures. One was the file-size ratchet: registering the new file pushedscripts/test-layout/layout.jsonto 2000 lines. Fixed in019cbc79aby folding the entry onto an existing line; the ratchet and layout guards were rerun green. The other isclaude-desktop-remote-hub.test.ts > connected Desktop uses hub IDs across a cold restart (stored profile=false), which fails the same way on an unmodifiedorigin/devcheckout (845ac6b87) on this machine and passes in CI. The full suite was not rerun after the one-line layout fix.019cbc79a: all required checks pass, including test shards 1–4 (https://github.com/lidge-jun/opencodex/actions/runs/39584927669)Checklist
proxy-formats.mden/ko relayed-header list;structure/transports/responses.md)Summary by CodeRabbit
New Features
voice-session-idheader in live and realtime connections.Bug Fixes