Skip to content

fix(server): ChatGPT sharing input-item rejections get their specific message - #36207

Open
cro13 wants to merge 1 commit into
pingdotgg:mainfrom
cro13:fix/codex-sharing-input-item-message
Open

cro13 wants to merge 1 commit into
pingdotgg:mainfrom
cro13:fix/codex-sharing-input-item-message

Conversation

@cro13

@cro13 cro13 commented Nov 13, 2026

Copy link
Copy Markdown

Problem

When ChatGPT sharing rejects an input item, T3 shows the vague "Codex used a feature that ChatGPT sharing does not support" instead of its own more specific "Codex sent an input item…" message. I hit this on 0.1.10-nightly (macOS) after Codex subagents ran under Connect with ChatGPT. The raw rejection in the provider log was:

{"message": "User subscription sharing currently supports only text, image, and file messages, item references, additional tools, compaction summaries, reasoning items, Web Search call items, developer function and custom tool call items, and programmatic tool calling items. Remove unsupported input items or use an API key instead.", "type": "invalid_request_error", "param": "input", "code": "subscription_sharing_unsupported_capability"}

classifyCodexManagedError picks the input-item message only when the text contains additional_tools. ChatGPT's real wording never contains that string: it lists "additional tools" as supported and ends with "Remove unsupported input items", so the specific branch never fires.

Change

Match input item instead of additional_tools. The existing input item 'additional_tools' is not supported fixture still matches, and the tool 'namespace' branch still runs first.

Scope

A small fix for an obvious bug in one function, so no issue. It is independent of #28143: that PR stops one source of these rejections (native subagents), while this one makes any input-item rejection report what it is.

Verification

  • Added ChatGPT's real rejection text as a row in the existing distinguishes unsupported tools from input items table. On main it fails with expected 'Codex used a feature that ChatGPT sha…' to include 'input item'; with the fix the file passes 6/6.
  • Runtime transcript: the classifier was given the exact payload.error shape CodexAdapterV2 receives (the response as a JSON string in message, codexErrorInfo: "other"):
    main code=subscription_sharing_unsupported_capability usageLimit=false
         message=Codex used a feature that ChatGPT sharing does not support. Use another provider for this request.
    fix  code=subscription_sharing_unsupported_capability usageLimit=false
         message=Codex sent an input item that ChatGPT sharing does not support. Use another provider for this request.
    
  • vp run check:changed passes: format, lint, both knip passes, typecheck (41 packages) and the selected tests. This ran on Node 22.23.3, not the pinned 26.12.1.
  • Not checked: the message shown in a client. Nothing in the UI changed; clients show the same failure.message field.

Created with Claude Opus 5.5 in Claude Code, running inside T3 Code.

… message

ChatGPT sharing rejects an unsupported input item with prose that lists
"additional tools" as supported and ends "Remove unsupported input items",
so the `additional_tools` check never matched and users saw the generic
"Codex used a feature" message. Match "input item" instead.
@github-actions github-actions Bot added vouch:unvouched Author is not yet trusted in the VOUCHED list. size:XS 0-9 changed lines (additions + deletions). labels Nov 13, 2026
@coderabbitai

coderabbitai Bot commented Nov 13, 2026

Copy link
Copy Markdown
Contributor

Explain Change →

No actionable comments were generated in the recent review.

Walkthrough

The unsupported-capability classifier now matches “input item” in the provider’s error text. A test covers the full message and checks the resulting managed-error message.

Changes: Unsupported input classification

Layer / File(s) Summary
Match and test unsupported input wording
apps/server/src/provider/CodexManagedErrors.ts, apps/server/src/provider/CodexManagedErrors.test.ts
The classifier now checks for “input item” instead of “additional_tools.” The test covers the provider’s full unsupported-input message.

Estimated code review effort: 2 (Simple) | ~5 minutes

Change: Bug fix

Suggested reviewers: shivamhwp

Merge Risk: Minimal · up to b1123

This change makes ChatGPT sharing rejections of unsupported input items show their specific message. No merge-blocking risk was found.

Pre-merge checks: Passed 4

Check name Status Explanation
Title check Passed The title names the main change: the ChatGPT sharing input-item rejection now gets its specific message. It matches the raw summary, which says the classifier now selects the input-item message when t…
Description check Passed The description follows the template. It has Problem, Change, Scope, and Verification sections. The problem includes expected behavior, the raw rejection text, and the environment (0.1.10-nightly, mac…
Linked Issues check Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check Passed Check skipped because no linked issues were found for this pull request.
Full details: Title check

Explanation

The title names the main change: the ChatGPT sharing input-item rejection now gets its specific message. It matches the raw summary, which says the classifier now selects the input-item message when the text contains "input item". The title is 77 characters, slightly long, but it is clear and specific.

Full details: Description check

Explanation

The description follows the template. It has Problem, Change, Scope, and Verification sections. The problem includes expected behavior, the raw rejection text, and the environment (0.1.10-nightly, macOS). The change explains the match-string fix. Scope says it is a small bug fix with no issue and states it is independent of #28143. Verification gives a failing-then-passing test result, a runtime transcript, and the check run. It also states what was not checked. The description does not link an issue, but the template allows a reason for no issue on a small obvious fix, and the author gave one. The model and harness line is present.

Finishing Touches

Generate unit tests (beta)

  • Create a new PR
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts
Recent review info

Run configuration

Commits

Reviewing files that changed from the base of the PR and between f313d0a and b112326.

Files selected for processing: 2

  • apps/server/src/provider/CodexManagedErrors.test.ts
  • apps/server/src/provider/CodexManagedErrors.ts

Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 9 remain after this review.

@macroscopeapp

macroscopeapp Bot commented Nov 13, 2026

Copy link
Copy Markdown
Contributor

Approvability

Verdict: Approved at b112326

Macroscope's review found this PR approvable — ChatGPT sharing input-item rejections now select the existing, specific error message using the provider’s actual wording. Error codes and handling remain unchanged, limiting the impact to clearer failure messaging.

You can add or adjust custom eligibility rules. Learn more.

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size:XS 0-9 changed lines (additions + deletions). vouch:unvouched Author is not yet trusted in the VOUCHED list.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant