fix(strix): recognize the hyphenated openai-direct fallback alias - #1256
fix(strix): recognize the hyphenated openai-direct fallback alias#1256seonghobae wants to merge 1 commit into
Conversation
STRIX_FALLBACK_MODELS' NVIDIA NIM entry ends in the hyphenated openai-direct/gpt-5.6-luna alias (the workflow's user-facing input spelling, also pinned verbatim by protected main's own trusted strix_required_workflow_smoke.sh, so that exact string cannot change). child_model_for_api_base() only recognized the underscored openai_direct/ form the primary-model case statement produces internally, so the fallback alias passed through unrewritten and reached LiteLLM as an unrecognized provider string. Observed three times in CI: NVIDIA NIM rate-limited the primary and first fallback model, the run advanced to the third fallback, and litellm.BadRequestError: LLM Provider NOT provided ended the scan instead of completing against direct OpenAI. Filed as a standalone fix against main rather than bundled into #1052 (whose branch already carries this same change): pull_request_target resolves job.workflow_sha to the base branch commit, so any .github PR's own "strix" check always fetches scripts/ci/strix_quick_gate.sh from protected main regardless of what the PR branch itself contains. A PR that touches this file cannot verify its own fix via that check; only a merge to main can.
|
Warning Review limit reached
Next review available in: 13 minutes Limit details: You’ve used the included review currently available. You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository. How can I continue?Wait for the limit to reset, then comment An organization admin can change what happens after included review limits in Billing. How do review limits work?CodeRabbit enforces per-developer PR review limits within each organization. For paid Pro and Pro+ reviews, CodeRabbit uses a developer's included PR review attempts over the past 7 days to set the current hourly allowance. At typical activity levels, the full plan allowance applies. Higher sustained activity can lower the allowance until earlier attempts leave the 7-day window. Please refer docs for additional details. Review details⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Plus Run ID: 📒 Files selected for processing (3)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
| openai_direct/* | openai-direct/*) | ||
| printf 'openai/%s\n' "${model#*/}" |
There was a problem hiding this comment.
📝 Info: Prefix strip change is equivalent
Replacing ${model#openai_direct/} with ${model#*/} is safe: the case guard only matches openai_direct/* or openai-direct/*, so the first / always ends the provider prefix. normalize_model (scripts/ci/strix_model_utils.sh:108-111) leaves slash-containing fallback candidates unchanged, so both alias spellings reach this arm and resolve to openai/.
Was this helpful? React with 👍 or 👎 to provide feedback.
|
@opencode-agent @cwl-noema-review current-head review for Required |
|
Superseded by #1213 exact head 5edaf36. The active successor normalizes the workflow-facing openai-direct alias in the shared model normalizer, dispatches it as LiteLLM openai, switches the cross-provider credential/API-base transport, and proves the real fallback path end to end. Closing this duplicate without merge; reopen only if that scope is removed from #1213. |
Summary
STRIX_FALLBACK_MODELS' NVIDIA NIM entry ends in the hyphenatedopenai-direct/gpt-5.6-lunaalias (the workflow's user-facing input spelling, also pinned verbatim by protected main's own trustedstrix_required_workflow_smoke.sh, so that exact string cannot change).child_model_for_api_base()inscripts/ci/strix_quick_gate.shonly recognized the underscoredopenai_direct/form the primary-model case statement produces internally, so the fallback alias passed through unrewritten and reached LiteLLM as an unrecognized provider string.#1052: NVIDIA NIM rate-limited the primary and first fallback model, the run advanced to the third fallback, andlitellm.BadRequestError: LLM Provider NOT providedended the scan instead of completing against direct OpenAI.openai-direct/*alongsideopenai_direct/*in the same case arm, both now rewriting to LiteLLM'sopenai/provider.Why standalone, not bundled into
#1052#1052already carries this identical change on its own branch, but it can never verify it:pull_request_targetresolvesjob.workflow_shato the base branch (main) commit, so any.githubPR's ownstrixcheck always fetchesscripts/ci/strix_quick_gate.shfrom protected main, regardless of what the PR branch itself contains. Any PR that touches this file is structurally unable to verify its own fix via that check — only a merge to main can. Filing this as a small, focused, standalone PR gives it the best chance of merging quickly so#1052and other.github-dependent repositories (e.g. fast-mlsirm) stop hitting the same deterministic failure.Test plan
test_gate_normalizes_hyphenated_openai_direct_fallback_aliasadded first, confirmed failing against the pre-fix code ('openai-direct/gpt-5.6-luna' != 'openai/gpt-5.6-luna').tests/test_strix_nvidia_nim_not_found_fallback.py: 16/16 passed after the fix.bash -n scripts/ci/strix_quick_gate.shsyntax check passed.🤖 Generated with Claude Code
https://claude.ai/code/session_01X19rsMish4NycoSRUcGzYm