What happened?
When using the Gemini CLI on the free tier, I'm frequently encountering a 429 Resource Exhausted API error, even with moderate usage that didn't previously cause this issue. The tool suggests it will switch to the gemini-2.5-flash model for the remainder of the session, but this behavior is inconsistent and sometimes the tool gets stuck in an error loop.
Steps to reproduce the behavior:
Start the Gemini CLI in a new session (gemini).
Engage in a conversation with a few prompts (e.g., asking for code generation or explanations).
After a few interactions, the 429 API Error appears.
The tool sometimes fails to automatically switch to the gemini-2.5-flash model and continues to show the error on subsequent prompts.
[API Error: [{
"error": {
"code": 429,
"message": "Resource exhausted. Please try again later. Please
refer to
https://cloud.google.com/vertex-ai/generative-ai/docs/error-code-429
for more details.",
"errors": [
{
"message": "Resource exhausted. Please try again later. Please
refer to
https://cloud.google.com/vertex-ai/generative-ai/docs/error-code-429
for more details.",
"domain": "global",
"reason": "rateLimitExceeded"
}
],
"status": "RESOURCE_EXHAUSTED"
}
}
]]
Possible quota limitations in place or slow response times detected.
Switching to the gemini-2.5-flash model for the rest of this session.
What did you expect to happen?
A clearer warning before hitting the rate limit.
A consistent and successful automatic switch to the gemini-2.5-flash model as indicated by the error message, without getting stuck.
Client information
CLI Version 0.8.1 │
│ Model gemini-2.5-pro │
│ Sandbox no sandbox │
│ OS win32 │
│ Auth Method OAuth │
│ IDE Client IDE
Login information
Google account
Anything else we need to know?
No response
What happened?
When using the Gemini CLI on the free tier, I'm frequently encountering a 429 Resource Exhausted API error, even with moderate usage that didn't previously cause this issue. The tool suggests it will switch to the gemini-2.5-flash model for the remainder of the session, but this behavior is inconsistent and sometimes the tool gets stuck in an error loop.
Steps to reproduce the behavior:
Start the Gemini CLI in a new session (gemini).
Engage in a conversation with a few prompts (e.g., asking for code generation or explanations).
After a few interactions, the 429 API Error appears.
The tool sometimes fails to automatically switch to the gemini-2.5-flash model and continues to show the error on subsequent prompts.
[API Error: [{
"error": {
"code": 429,
"message": "Resource exhausted. Please try again later. Please
refer to
https://cloud.google.com/vertex-ai/generative-ai/docs/error-code-429
for more details.",
"errors": [
{
"message": "Resource exhausted. Please try again later. Please
refer to
https://cloud.google.com/vertex-ai/generative-ai/docs/error-code-429
for more details.",
"domain": "global",
"reason": "rateLimitExceeded"
}
],
"status": "RESOURCE_EXHAUSTED"
}
}
]]
Possible quota limitations in place or slow response times detected.
Switching to the gemini-2.5-flash model for the rest of this session.
What did you expect to happen?
A clearer warning before hitting the rate limit.
A consistent and successful automatic switch to the gemini-2.5-flash model as indicated by the error message, without getting stuck.
Client information
CLI Version 0.8.1 │
│ Model gemini-2.5-pro │
│ Sandbox no sandbox │
│ OS win32 │
│ Auth Method OAuth │
│ IDE Client IDE
Login information
Google account
Anything else we need to know?
No response