AI_RetryError: Failed after 4 attempts. Last error: Too Many Requests
I've searched around and this seems to be related to provider. Anyone else? #2018 #2116
This issue might be a duplicate of existing issues. Please check:
- #2018: Very similar AI_RetryError with "Failed after 4 attempts" and "Provider returned error" - also mentions provider-related issues
- #2244: Rate limiting issue with "rate_limit_exceeded" - similar retry/rate limiting symptoms
- #2245: AI_APICallError with OpenRouter provider - related to provider authentication/API issues
Feel free to ignore if none of these address your specific case.
What provider are you using?
What provider are you using?
Copilot and claude.
Nevermind... Only copilot is having the issue. Probaly provider issue.
You may be getting rate limited? 2 things:
- check your copilot dashboard
- you can try opencode auth logout and log back in again
we can also try looking at your logs
@andreluisos can you confirm this is still happening? I recall seeing something similar, but it was a while ago, and nothing since the (subsequent) latest update.
I now (v1.0.126) experience OC (apparently) spamming X.ai to the point where I see the red error message "Too many requests..."
Trying to divine what is happening from the logs is either neigh impossible... or I'm holding the wrong chicken and standing on the wrong leg - @rekram1-node any hints on where in the logs we can find what is happening?
@taqtiqa-mark what kind of logs are you looking for exactly? when you get 429s we continue to retry but with a backoff that respects the retry-after ratelimiting headers
The retry message you see is taken directly from the response from the server, or it should be
@taqtiqa-mark what kind of logs are you looking for exactly?
Ideally the full transcript of the API (pre-encryption/HTTPS) messages sent/received. There is no way my message submissions triggered a rate limit violation, 10-20 messages tops across a couple of new sessions.
I also have a sneeking suspicion about what happens when OC chokes on the the XML parsing (mentioned in other issues), so it'd be nice to see the logs of that too.
@taqtiqa-mark what kind of logs are you looking for exactly?
@rekram1-node progress is probably blocked by issue #4999 ?