fix: forward originator to Codex Apps MCP - #31481
Conversation
|
All contributors have signed the CLA ✍️ ✅ |
|
I have read the CLA Document and I hereby sign the CLA |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 41f09ce711
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| .config | ||
| self.runtime_config_with_context( | ||
| McpServerContributionContext::global(config), | ||
| /*originator*/ None, |
There was a problem hiding this comment.
This still leaves connector discovery and the no-thread MCP paths without an originator
Is this wanted?
| } | ||
|
|
||
| #[cfg(test)] | ||
| mod tests { |
There was a problem hiding this comment.
move this to a test file please (see how it is done in the rest of the codebase)
…es-desktop-originator # Conflicts: # codex-rs/codex-mcp/src/mcp/mod.rs # codex-rs/codex-mcp/src/mcp/mod_tests.rs
Summary
originatorheader on ChatGPT-hosted Apps and plugin-runtime MCP requests.X-OpenAI-Product-Skuheader.Why
Sites project creation is logged downstream of Apps MCP. Production validation found
CODEX_UNKNOWN_DEFAULTproject-created threads that matchedcodex_surface=desktop_appandoriginator=Codex Desktopinfact_codex_cli(query).The hosted Apps MCP configuration forwarded the product SKU but not Codexs canonical originator, so codex-backend could not derive
CODEX_DESKTOP_APPfor those tool calls.Validation
just fmtCARGO_HOME=/private/tmp/codex-cargo-home CARGO_TARGET_DIR=/private/tmp/codex-target just test -p codex-mcp(106 passed)CARGO_HOME=/private/tmp/codex-cargo-home CARGO_TARGET_DIR=/private/tmp/codex-target just fix -p codex-mcp