Skip to content

fix: allow model variants in OAuth Codex filter - #7608

Closed
zerone0x wants to merge 1 commit into
anomalyco:devfrom
zerone0x:fix/model-variant-filtering
Closed

zerone0x wants to merge 1 commit into
anomalyco:devfrom
zerone0x:fix/model-variant-filtering

Conversation

@zerone0x

Copy link
Copy Markdown
Contributor

Summary

  • Fixed model variant filtering in Codex OAuth plugin to allow user-defined variants
  • Previously only exact model IDs were allowed (e.g., gpt-5.2-codex)
  • Now variants like gpt-5.2-codex-low, gpt-5.2-codex-high, gpt-5.2-codex-xhigh are also allowed

Problem

Users who defined custom reasoning effort variants in their opencode.json under the openai provider found that these variants were being filtered out by the Codex plugin's OAuth loader.

Solution

Changed the filter logic from exact Set matching to prefix-based matching.

Fixes #7593

Previously, the Codex OAuth plugin only allowed exact model ID matches
(e.g., gpt-5.2-codex). This prevented users from using custom variants
defined in their opencode.json (e.g., gpt-5.2-codex-low, gpt-5.2-codex-high).

The fix changes the filter to allow both base models and their variants
by checking if the model ID starts with an allowed base model followed
by a hyphen.

Fixes anomalyco#7593

Co-Authored-By: Claude Opus 4.5 <[email protected]>
@github-actions

Copy link
Copy Markdown
Contributor

The following comment was made by an LLM, it may be inaccurate:

No duplicate PRs found

@abhirup-dev

Copy link
Copy Markdown

Yes this has turned out to be a major pain point and blocker while moving from the codex-oauth plugin to the inbuilt one in opencode

@github-actions

Copy link
Copy Markdown
Contributor

Closing this pull request because it has had no updates for more than 60 days. If you plan to continue working on it, feel free to reopen or open a new PR.

@github-actions github-actions Bot closed this Mar 15, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

model selection only has GPT-5.2 Codex, not low/medium/high/xhigh even through opencode.json has it

2 participants