Repository navigation
fix(codex): prevent catalog agents in ChatGPT sharing - #28143
matteodante wants to merge 2 commits into
Conversation
ApprovabilityVerdict: Needs Human Approval Macroscope's review found this PR requires human approval — The change disables catalog-provided native agents for managed ChatGPT-sharing sessions to prevent unsupported-capability failures. Human review is required to confirm this change to the runtime’s effective default capabilities. You can add or adjust custom eligibility rules. Learn more. |
|
No actionable comments were generated in the recent review.
|
| Layer / File(s) | Summary |
|---|---|
Managed launch arguments and tests apps/server/src/provider/CodexManagedRuntime.ts, apps/server/src/provider/CodexManagedRuntime.test.ts |
managedCodexLaunchArgs adds agents.enabled=false. The tests check the launch argument and use Path.join for the expected additional-account home-path suffix. |
Estimated code review effort: 2 (Simple) | ~5 minutes
Change: Bug fix
Suggested reviewers: juliusmarminge
Merge Risk: 
Minimal · up to c9b0e
-
No actionable merge risk was identified; the change is ready to merge.
Pre-merge checks: 
4
-
Full details: Description check
-
Explanation
The description includes the required Problem, Change, Scope and approval, and Verification sections. It explains the failure mode, implementation, test coverage, approval status, limitations, and observed results. It also identifies that maintainer approval remains pending rather than claiming approval that was not received.
-
Finishing Touches
-
Generate unit tests (beta)
-
- Create a new PR
-
- Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts
Build the overlay-home expectation with the injected Path service. A POSIX-only substring stopped both additional-account cases before the catalog-agent assertions on Windows. The existing four-case matrix now passes and catches a missing agents.enabled override in every case.
Backport the prevention fix from pingdotgg#28143. Set agents.enabled=false alongside the existing feature overrides so catalog metadata cannot re-enable native agents. Extend the existing account/executable test matrix and use a portable home-path assertion.
Problem
Managed Codex sessions using Connect with ChatGPT already disable
features.multi_agentandfeatures.multi_agent_v2. A model catalog entry withmulti_agent_version: "v2"can still expose native agent tools, leading tosubscription_sharing_unsupported_capabilityforinputand repeated failures when continuing the affected conversation.Change
Add
agents.enabled=falseto the managed runtime launch overrides, keeping both existing feature flags disabled. Codex uses this setting to select the disabled-agent override before falling back to the model catalog.Assert the setting in the existing primary/additional-account and managed/local-executable test matrix. Build the existing home-path assertion with
path.joinso the additional-account cases also reach the agent assertions on Windows.Scope and approval
This completes the managed-sharing restriction introduced by merged PR #17499. Related evidence: #17679 and the native-agent failures in #21061.
The established capability is ChatGPT subscription sharing through the managed
openai_token_sharingruntime. Its launch configuration already disables native multi-agent features;agents.enabledcloses the model-catalog fallback in that same configuration. The additional test correction is needed to exercise that restriction across the full existing matrix on Windows.The implementation follows @pirut's closed, unmerged #20270. The maintainer takeover comment explicitly left human approval outstanding. No maintainer approval is claimed for this PR. Disabling catalog-provided native agents changes the runtime's effective capabilities, so Macroscope's requested human review remains pending.
Verification
vp test run apps/server/src/provider/CodexManagedRuntime.test.tspasses all four existing cases. Before the path correction, both additional-account cases failed at the POSIX-only path assertion; that assertion is also present in base commit79f1fadfc602.agents.enabled=falseargument. Restoring it makes the suite pass.vp run check:changed 79f1fadfc6020b820d541ca4691d2feebb15dd1bpasses formatting, lint, both knip checks, generated GraphQL verification, typechecking of three affected packages, and all five selected tests.git diff --checkpasses.agents.enabled=falseexposed none. This follow-up changes only the test's path assertion; that CLI probe was not rerun.Upstream Actions require maintainer approval before execution and are not counted as passing CI. A complete T3 conversation with a real account and other operating systems was not exercised. The change prevents new native-agent histories; existing affected conversations are not repaired. Separate unsupported-capability reports such as
tool_searchremain outside this fix.Original runtime implementation: GPT-6 Astra through the Codex harness in T3 Code. Windows test correction and PR documentation: GPT-6 through Codex.