对齐 Api 与 Request 的可重试状态码

TripoError::is_retryable 的 Api 分支补充 408 与 425,与 Request 分支的可重试集合保持一致
This commit is contained in:
2026-09-19 13:15:31 +08:00
parent f4996d7ac2
commit b87d9358e5
@@ -150,7 +150,7 @@ impl std::error::Error for TripoError {}
impl TripoError {
pub fn is_retryable(&self) -> bool {
match self {
Self::Api { status, .. } => matches!(status, Some(429 | 500..=599)),
Self::Api { status, .. } => matches!(status, Some(408 | 425 | 429 | 500..=599)),
Self::Request { status, .. } => {
status.is_none() || matches!(status, Some(408 | 425 | 429 | 500..=599))
}