Google AI Studio Build Agent repeatedly terminates during project edits

Hi,

I am experiencing repeated failures with the Google AI Studio Build Agent while working on an existing TaskFlow project.

The error shown is:

“Encountered retryable error from model provider:
Agent execution terminated due to error.”

Details:

  • The TaskFlow application itself is working correctly.
  • Firebase Authentication and Firestore are working correctly.
  • The project preview works normally.
  • The Build Agent can inspect files and make changes successfully at first.
  • During later edit requests, the agent repeatedly terminates with the error above.
  • Retrying the same request produces the same failure.
  • This has happened multiple times during the same project/session.

The latest failure happened while the agent was making relatively small frontend changes. Before terminating, it had already successfully read and edited several files.

This makes it appear to be a Build Agent/model-provider/session issue rather than an application runtime or Firebase issue.

I have attached a screenshot showing the repeated agent termination errors.

Could you please investigate this?

I would prefer not to recreate the project because the existing application and Firebase integration are working correctly.

Environment:

Hello @Aniket_rai ,

Could you share a few more details so we can narrow this down?

Are you seeing this in your other apps as well, or only in this one? Can you share the prompt you were running when the error appeared? Are you on the free tier, or do you have a paid plan? Your applet ID would also help us to look at your specific case.

if you check this forum you will see this is a known issue. many people are experiencing this.

the agent ends with one of these during project edits:
(1) request timed out.
(2) quota exceeded even though there is still quota.
(3) the error that this person mentioned here on the post

Google AI Studio Build Agent is repeatedly failing across multiple models with:

"Encountered retryable error from model provider:

Agent execution terminated due to error."

Environment:

- Google AI Studio Build

- Google AI Pro subscriber

- No paid Gemini API billing / no Pay-per-request setup

- Project: CMS_DEV

- Framework: Next.js / React / TypeScript

- GitHub repository connected

- Affected models: Gemini 3.7 Flash, Gemini 3.8 Flash, and other available models

Observed behavior:

- The agent previously worked normally on this same project.

- The project itself and GitHub repository are healthy.

- The failure now happens repeatedly across different models and fresh chats.

- Even a minimal diagnostic prompt with no Git operations, no build, no package installation and no file modifications fails with the same provider error.

- Switching models does not resolve the issue.

- Retrying repeatedly produces the same failure.

- The failure occurs before useful diagnostic output is returned.

Minimal reproduction:

1. Open the existing AI Studio Build app.

2. Start a fresh chat.

3. Send a small read-only diagnostic prompt.

4. Agent starts “Working”.

5. After roughly 20–30 seconds it terminates with:

“Encountered retryable error from model provider: Agent execution terminated due to error.”

This appears to be a Build Agent / model-provider / account or session backend issue rather than application code.

Applet ID:

Tier / subscription:

Google AI Pro

No paid Gemini API billing

Please check whether the Build Agent entitlement, provider routing, account state or applet backend state is corrupted or currently affected by an incident.

I can provide screenshots and exact timestamps privately if needed.

Have you tried asking it. I had the same.

Here are some screenshots of the chat

There was more before this but much the same

First I tried telling it to stop on errors ignored me

Then I asked can it stop wasting tokens … errors repeating

Then I changed to 3.7 (which people say now plays up too) and it told me why. This dont really help but you know what’s happening and it’s not your fault

I can reproduce the same issue in a brand-new Google AI Studio Build app.

Prompt used: “Reply with exactly: OK. Do not create, read, or modify any files.”

The Build Agent stays on “Working / Generating app” and does not complete.

This also happens in my existing project, where the same Agent execution terminated error occurs.

Environment: Google AI Studio Build, Gemini 3.8 Flash, Google AI Pro, Windows/Chrome.

The preview itself works; the problem is specifically the Build Agent execution.