fix(config): avoid Anthropic startup crash (#45520)

Co-authored-by: Val Alexander <bunsthedev@gmail.com>
This commit is contained in:
Val Alexander
2026-03-13 18:28:33 -05:00
committed by GitHub
parent 63802c1112
commit 868fd32ee7
4 changed files with 48 additions and 8 deletions

View File

@@ -121,6 +121,12 @@ describe("model-selection", () => {
defaultProvider: "anthropic",
expected: { provider: "anthropic", model: "claude-sonnet-4-6" },
},
{
name: "keeps dated anthropic model ids unchanged",
variants: ["anthropic/claude-sonnet-4-20250514", "claude-sonnet-4-20250514"],
defaultProvider: "anthropic",
expected: { provider: "anthropic", model: "claude-sonnet-4-20250514" },
},
{
name: "normalizes deprecated google flash preview ids",
variants: ["google/gemini-3.1-flash-preview", "gemini-3.1-flash-preview"],