fix: align GitHub Copilot model variants with catalog#3353
fix: align GitHub Copilot model variants with catalog#3353divlook wants to merge 5 commits intocode-yeongyu:devfrom
Conversation
|
All contributors have signed the CLA. Thank you! ✅ |
There was a problem hiding this comment.
No issues found across 8 files
Confidence score: 5/5
- Automated review surfaced no issues in the provided summaries.
- No files require special attention.
Auto-approved: Aligns GitHub Copilot variants with catalog capabilities, splitting fallback chains to ensure valid variant requests (e.g., high instead of max for Opus), backed by updated regression tests.
There was a problem hiding this comment.
Pull request overview
Aligns GitHub Copilot-specific model fallback entries with the models.jsonl catalog by separating Copilot variants from shared fallback chains, and updates regression coverage to lock in the new ordering/normalization behavior.
Changes:
- Split shared fallback-chain entries into provider-specific siblings for Copilot Claude Opus (forcing
variant: "high") and Copilot Gemini (omittingvariant). - Add/adjust tests covering settings compatibility and Copilot runtime capability normalization edge-cases.
- Update model-fallback tests/snapshots and isolate the auto-update plugin-entry test from user config leakage via an isolated config dir.
Reviewed changes
Copilot reviewed 8 out of 8 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
| src/shared/model-settings-compatibility.test.ts | Adds regression tests for Copilot variant handling when metadata limits variants / when variant is omitted. |
| src/shared/model-requirements.ts | Splits Copilot Claude Opus + Gemini entries from shared chains to match catalog expectations. |
| src/shared/model-requirements.test.ts | Updates ordering/length assertions to reflect split fallback entries. |
| src/shared/model-capabilities.test.ts | Adds tests for Copilot runtime metadata edge cases (object-form variants, empty variants object). |
| src/plugin/event.model-fallback.test.ts | Updates model-fallback expectations to prefer the new adjacent Copilot Opus split entry. |
| src/hooks/model-fallback/hook.test.ts | Updates fallback progression assertions to match the new chain ordering and Copilot Opus high variant. |
| src/hooks/auto-update-checker/checker/plugin-entry.test.ts | Prevents local user config contamination by forcing an isolated OPENCODE_CONFIG_DIR in the spawned process. |
| src/cli/snapshots/model-fallback.test.ts.snap | Snapshot updates reflecting new fallback ordering and Copilot variant behavior. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
|
I have read the CLA Document and I hereby sign the CLA |
|
recheck |
|
Follow-up cleanup for stale GitHub Copilot nano references is tracked separately in #3359. This PR intentionally keeps that work out of scope and only covers the Copilot variant alignment changes. |
Summary
opencode models github-copilot --verboseoutput by splitting Copilot-specific Opus and Gemini entries from shared fallback chainsbun run typecheck,bun test, andbun run buildChanges
claude-opus-4.6fallback entries tovariant: highbecause the currentopencode models github-copilot --verboseoutput exposes onlylow,medium, andhighgemini-3.1-pro-previewfallback entries because the currentopencode models github-copilot --verboseoutput does not expose a Gemini variant set thereTesting
bun run typecheckbun testbun run buildNotes
dev