-
Notifications
You must be signed in to change notification settings - Fork 0
Open
Labels
bugSomething isn't workingSomething isn't working
Description
Problem
The Agent encounters "429 Too Many Requests" errors from the Copilot API, causing the agent to fail and throw an error.
Error message:
Agent error: Copilot API error: 429 Too Many Requests
Expected Behavior
The Agent should gracefully handle 429 rate limit responses by:
- Implementing exponential backoff/retry logic
- Displaying a user-friendly message about rate limiting
- Continuing operation once rate limit resets
Current Behavior
- Agent fails immediately when hitting a 429 response
- No retry logic is implemented
- User sees a cryptic error message
Proposed Solution
Implement rate limit handling:
- Detect 429 status code from API responses
- Parse
Retry-Afterheader if present - Implement exponential backoff with jitter
- Show progress/waiting indicator to user
- Retry request after appropriate delay
- Add max retry limit to prevent infinite loops
Files to Investigate
- Agent API call implementations
- HTTP client configuration
- Error handling middleware
Acceptance Criteria
- 429 responses are detected and handled gracefully
- Retry logic with exponential backoff implemented
- User sees informative message about rate limiting
- Agent continues after rate limit resets
- Max retry limit prevents infinite loops
- Add tests for rate limit handling
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working