fix(model): treat 'bad request' as retryable error for GitHub Copilot fallback (#3130)

GitHub Copilot performs rolling model updates which sometimes return
'400 Bad Request' when a model is temporarily unavailable. This error
was not in the retryable message patterns, causing model fallback to
not trigger and users getting stuck.

Changes:
- Added 'bad request' to RETRYABLE_MESSAGE_PATTERNS in model-error-classifier.ts
- Added test cases for 'bad request' pattern matching

Fixes #3130
This commit is contained in:
YeonGyu-Kim
2026-04-05 10:17:50 +09:00
parent 1562b7d148
commit 0cbfdec76e
2 changed files with 23 additions and 0 deletions
+1
View File
@@ -52,6 +52,7 @@ const RETRYABLE_MESSAGE_PATTERNS = [
"over limit",
"overloaded",
"bad gateway",
"bad request",
"unknown provider",
"provider not found",
"model_not_supported",