mirror of
https://github.com/fabro-sh/fabro.git
synced 2026-09-11 22:53:00 +00:00
Map all 5xx status codes to ServerError
Expands the HTTP status code mapping from 500-504 to 500-599 so that uncommon 5xx codes (505, 507, etc.) are correctly classified as retryable ServerError instead of falling through to message-based heuristics. The existing 529 (Overloaded) handling is subsumed by the broader range. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
parent
5d3a2d3cfa
commit
78c0910075
1 changed files with 1 additions and 1 deletions
|
|
@ -232,7 +232,7 @@ pub fn error_from_status_code(
|
|||
}
|
||||
413 => ProviderErrorKind::ContextLength,
|
||||
429 => ProviderErrorKind::RateLimit,
|
||||
500..=504 | 529 => ProviderErrorKind::Server,
|
||||
500..=599 => ProviderErrorKind::Server,
|
||||
// For ambiguous status codes (400, 422, etc.), use message-based classification
|
||||
_ => {
|
||||
let lower_msg = detail.message.to_lowercase();
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue