feat: Parse and use retryDelay from Google API RateLimitExceeded errors (#4124)
Signed-off-by: sings-to-bees-on-wednesdays <222684290+sings-to-bees-on-wednesdays@users.noreply.github.com> Co-authored-by: Jack Amadeo <jackamadeo@block.xyz> Co-authored-by: Jack Amadeo <jackamadeo@squareup.com>
This commit is contained in:
committed by
GitHub
parent
94cf5c85a0
commit
b5c133cecb
@@ -251,7 +251,7 @@ impl SubAgent {
|
||||
last_error = Some(anyhow::anyhow!("Context length exceeded"));
|
||||
break;
|
||||
}
|
||||
Err(ProviderError::RateLimitExceeded(_)) => {
|
||||
Err(ProviderError::RateLimitExceeded { .. }) => {
|
||||
self.set_status(SubAgentStatus::Completed("Rate limit exceeded".to_string()))
|
||||
.await;
|
||||
last_error = Some(anyhow::anyhow!("Rate limit exceeded"));
|
||||
|
||||
Reference in New Issue
Block a user