Bug: "Agent terminated due to error" on all Gemini models despite 100% quota

Hello, I am a Google AI Pro user. I am experiencing a new issue while using the Antigravity tool. As you can see in the attached screenshot, even though my Gemini model quota is at 100%, I keep getting an “Agent terminated due to error” message no matter which Gemini model I try to use. The prompt fails immediately. To be clear, this error occurs even when I start a completely new, empty chat and send a very short, simple prompt. It is not caused by a long conversation or an overloaded context window. Could you please help resolve this issue?

Here is the debug info for the error:

Trajectory ID: 930a1904-b820-4500-9f61-e0a581105705
Error: agent executor error: could not convert a single message before hitting truncation
(1) attached stack trace
– stack trace:
| google3/third_party/jetski/cortex/cortex.(*CascadeManager).executeHelper.func1
| third_party/jetski/cortex/cascade_manager.go:2096
| google3/third_party/jetski/cortex/cortex.(*CascadeManager).executeHelper.func2
| third_party/jetski/cortex/cascade_manager.go:2144
Wraps: (2) agent executor error
Wraps: (3) attached stack trace
– stack trace:
| google3/third_party/jetski/cortex/chatconverters/chatconverters.(*TrajectoryChatConverter).GetNumTokensSinceLastCheckpoint
| third_party/jetski/cortex/chatconverters/trajectory_chat_converter.go:550
| google3/third_party/jetski/cortex/mixins/mixins.GetConversationalHooks.NewCheckpointHook.func7.1
| third_party/jetski/cortex/executors/posthooks/checkpoint_hook.go:43
| google3/third_party/jetski/cortex/executors/executors.(*CascadeWrapper).ViewTrajectory
| third_party/jetski/cortex/executors/cascade_wrapper.go:258
| google3/third_party/jetski/cortex/mixins/mixins.GetConversationalHooks.NewCheckpointHook.func7
| third_party/jetski/cortex/executors/posthooks/checkpoint_hook.go:33
| google3/third_party/gemini_coder/framework/executor/executor.(*Executor).executeLoop
| third_party/gemini_coder/framework/executor/executor.go:388
| google3/third_party/gemini_coder/framework/executor/executor.(*Executor).Execute
| third_party/gemini_coder/framework/executor/executor.go:277
| google3/third_party/jetski/cortex/cortex.(*CascadeManager).executeHelper.func1
| third_party/jetski/cortex/cascade_manager.go:2061
| google3/third_party/jetski/cortex/cortex.(*CascadeManager).executeHelper.func2
| third_party/jetski/cortex/cascade_manager.go:2144
Wraps: (4) attached stack trace
– stack trace:
| google3/third_party/jetski/cortex/chatconverters/chatconverters.(*TrajectoryChatConverter).TrajectoryToChatMessagesFromNCheckpointsAgo
| third_party/jetski/cortex/chatconverters/trajectory_chat_converter.go:1135
| google3/third_party/jetski/cortex/chatconverters/chatconverters.(*TrajectoryChatConverter).GetNumTokensSinceLastCheckpoint
| third_party/jetski/cortex/chatconverters/trajectory_chat_converter.go:548
| google3/third_party/jetski/cortex/mixins/mixins.GetConversationalHooks.NewCheckpointHook.func7.1
| third_party/jetski/cortex/executors/posthooks/checkpoint_hook.go:43
| google3/third_party/jetski/cortex/executors/executors.(*CascadeWrapper).ViewTrajectory
| third_party/jetski/cortex/executors/cascade_wrapper.go:258
| google3/third_party/jetski/cortex/mixins/mixins.GetConversationalHooks.NewCheckpointHook.func7
| third_party/jetski/cortex/executors/posthooks/checkpoint_hook.go:33
| google3/third_party/gemini_coder/framework/executor/executor.(*Executor).executeLoop
| third_party/gemini_coder/framework/executor/executor.go:388
| google3/third_party/gemini_coder/framework/executor/executor.(*Executor).Execute
| third_party/gemini_coder/framework/executor/executor.go:277
| google3/third_party/jetski/cortex/cortex.(*CascadeManager).executeHelper.func1
| third_party/jetski/cortex/cascade_manager.go:2061
| […repeated from below…]
Wraps: (5) attached stack trace
– stack trace:
| google3/third_party/jetski/cortex/chatconverters/chatconverters.init
| third_party/jetski/cortex/chatconverters/trajectory_chat_converter.go:44
| runtime.doInit1
| third_party/go/gc/src/runtime/proc.go:8105
| runtime.doInit
| third_party/go/gc/src/runtime/proc.go:8072
| runtime.main
| third_party/go/gc/src/runtime/proc.go:258
| runtime.goexit
| third_party/go/gc/src/runtime/asm_amd64.s:1774
Wraps: (6) could not convert a single message before hitting truncation
Error types: (1) *withstack.withStack (2) *errutil.withPrefix (3) *withstack.withStack (4) *withstack.withStack (5) *withstack.withStack (6) *errutil.leafError

7 Likes

The same its happening to me, i think its related to this version , do you have any news or solutions?

i’ve same issues(1) attached stack trace
– stack trace:
| google3/third_party/jetski/cortex/cortex.(*CascadeManager).executeHelper.func1
| third_party/jetski/cortex/cascade_manager.go:2096
| […repeated from below…]
Wraps: (2) agent executor error
Wraps: (3) attached stack trace
– stack trace:
| google3/third_party/jetski/cortex/chatconverters/chatconverters.init
| third_party/jetski/cortex/chatconverters/trajectory_chat_converter.go:44
| runtime.doInit1
| third_party/go/gc/src/runtime/proc.go:8105
| runtime.doInit
| third_party/go/gc/src/runtime/proc.go:8072
| runtime.main
| third_party/go/gc/src/runtime/proc.go:258
| runtime.goexit
| third_party/go/gc/src/runtime/asm_amd64.s:1774
Wraps: (4) could not convert a single message before hitting truncation
Error types: (1) *withstack.withStack (2) *errutil.withPrefix (3) *withstack.withStack (4) *errutil.leafError

I’ve been dealing with this issue for over two weeks now. It originally started back in Antigravity version 1.19.6. For a whole week, I thought the problem was on my end and tried a bunch of different things to fix it. After a whole week went to waste, I realized it was entirely a Google Gemini bug.

When version 1.20.5 was released, my issue was actually fixed that same day. However, just two days after the update, the exact same problem started happening again. The issue only occurs with the Gemini models. The Claude models work perfectly fine, but their quotas are severely limited.

My hands are basically tied at this point. If things keep going like this, I’m seriously considering canceling my subscription soon.

2 Likes

Same issue on me. I have done almost nothing but the model quotas seem to be full. I’m gonna unsubscribe my membership soon.

2 Likes

Same issue here is gets terminated again and again
this is the debug error
Trajectory ID: 1f9bcd9b-1b86-4fdc-a5b8-9e177e23db0a
Error: agent executor error: could not convert a single message before hitting truncation
(1) attached stack trace
– stack trace:
| google3/third_party/jetski/cortex/cortex.(*CascadeManager).executeHelper.func1
| third_party/jetski/cortex/cascade_manager.go:2096
| google3/third_party/jetski/cortex/cortex.(*CascadeManager).executeHelper.func2
| third_party/jetski/cortex/cascade_manager.go:2144
Wraps: (2) agent executor error
Wraps: (3) attached stack trace
– stack trace:
| google3/third_party/jetski/cortex/chatconverters/chatconverters.(*TrajectoryChatConverter).GetNumTokensSinceLastCheckpoint
| third_party/jetski/cortex/chatconverters/trajectory_chat_converter.go:550
| google3/third_party/jetski/cortex/mixins/mixins.GetConversationalHooks.NewCheckpointHook.func7.1
| third_party/jetski/cortex/executors/posthooks/checkpoint_hook.go:43
| google3/third_party/jetski/cortex/executors/executors.(*CascadeWrapper).ViewTrajectory
| third_party/jetski/cortex/executors/cascade_wrapper.go:258
| google3/third_party/jetski/cortex/mixins/mixins.GetConversationalHooks.NewCheckpointHook.func7
| third_party/jetski/cortex/executors/posthooks/checkpoint_hook.go:33
| google3/third_party/gemini_coder/framework/executor/executor.(*Executor).executeLoop
| third_party/gemini_coder/framework/executor/executor.go:388
| google3/third_party/gemini_coder/framework/executor/executor.(*Executor).Execute
| third_party/gemini_coder/framework/executor/executor.go:277
| google3/third_party/jetski/cortex/cortex.(*CascadeManager).executeHelper.func1
| third_party/jetski/cortex/cascade_manager.go:2061
| google3/third_party/jetski/cortex/cortex.(*CascadeManager).executeHelper.func2
| third_party/jetski/cortex/cascade_manager.go:2144
Wraps: (4) attached stack trace
– stack trace:
| google3/third_party/jetski/cortex/chatconverters/chatconverters.(*TrajectoryChatConverter).TrajectoryToChatMessagesFromNCheckpointsAgo
| third_party/jetski/cortex/chatconverters/trajectory_chat_converter.go:1135
| google3/third_party/jetski/cortex/chatconverters/chatconverters.(*TrajectoryChatConverter).GetNumTokensSinceLastCheckpoint
| third_party/jetski/cortex/chatconverters/trajectory_chat_converter.go:548
| google3/third_party/jetski/cortex/mixins/mixins.GetConversationalHooks.NewCheckpointHook.func7.1
| third_party/jetski/cortex/executors/posthooks/checkpoint_hook.go:43
| google3/third_party/jetski/cortex/executors/executors.(*CascadeWrapper).ViewTrajectory
| third_party/jetski/cortex/executors/cascade_wrapper.go:258
| google3/third_party/jetski/cortex/mixins/mixins.GetConversationalHooks.NewCheckpointHook.func7
| third_party/jetski/cortex/executors/posthooks/checkpoint_hook.go:33
| google3/third_party/gemini_coder/framework/executor/executor.(*Executor).executeLoop
| third_party/gemini_coder/framework/executor/executor.go:388
| google3/third_party/gemini_coder/framework/executor/executor.(*Executor).Execute
| third_party/gemini_coder/framework/executor/executor.go:277
| google3/third_party/jetski/cortex/cortex.(*CascadeManager).executeHelper.func1
| third_party/jetski/cortex/cascade_manager.go:2061
| […repeated from below…]
Wraps: (5) attached stack trace
– stack trace:
| google3/third_party/jetski/cortex/chatconverters/chatconverters.init
| third_party/jetski/cortex/chatconverters/trajectory_chat_converter.go:44
| runtime.doInit1
| third_party/go/gc/src/runtime/proc.go:8105
| runtime.doInit
| third_party/go/gc/src/runtime/proc.go:8072
| runtime.main
| third_party/go/gc/src/runtime/proc.go:258
| runtime.goexit
| third_party/go/gc/src/runtime/asm_amd64.s:1774
Wraps: (6) could not convert a single message before hitting truncation
Error types: (1) *withstack.withStack (2) *errutil.withPrefix (3) *withstack.withStack (4) *withstack.withStack (5) *withstack.withStack (6) *errutil.leafError

1 Like

This instability has basically caused me to abandon Antigravity for now, in favor of one of the competitors. Even though, I would love to have a Google AI pro subscription to give me overall access. But the crashes are intolerable

2 Likes

I am on the latest version of Antigravity, I have 100% quota left with Gemini 3.1 Pro models and encountering the same issue. It does some initial generation of plans but fails right after that. I would also like to raise the issue of varying model quotas throughout the day. In the morning, I had 5 hours reset with the Claude models and in the evening, it changed to 5 days reset with 60% quota remaining (which is strange because I used Opus 4.6 for just one task).
Clearly, there are some bugs with the model quota and task execution. Antigravity Devs, please fix this ASAP.

Trajectory ID: 228653fe-571c-44bc-bdb9-8c17bf0c2f57
Error: agent executor error: could not convert a single message before hitting truncation
(1) attached stack trace
– stack trace:
| google3/third_party/jetski/cortex/cortex.(*CascadeManager).executeHelper.func1
| third_party/jetski/cortex/cascade_manager.go:2096
| […repeated from below…]
Wraps: (2) agent executor error
Wraps: (3) attached stack trace
– stack trace:
| google3/third_party/jetski/cortex/chatconverters/chatconverters.init
| third_party/jetski/cortex/chatconverters/trajectory_chat_converter.go:44
| runtime.doInit1
| third_party/go/gc/src/runtime/proc.go:8105
| runtime.doInit
| third_party/go/gc/src/runtime/proc.go:8072
| runtime.main
| third_party/go/gc/src/runtime/proc.go:258
| runtime.goexit
| third_party/go/gc/src/runtime/asm_amd64.s:1774
Wraps: (4) could not convert a single message before hitting truncation
Error types: (1) *withstack.withStack (2) *errutil.withPrefix (3) *withstack.withStack (4) *errutil.leafError

2 Likes

I also have this issue, and it’s been going on for almost a week. So I switched to not using antigravity anymore.

Ran into something similar. Do you have skills installed? I removed my skills directory and seems to have fixed the issue for now. I had installed the antigravity-awesome-skills repo and guessing the latest update was not happy with it? Not sure.

In my project, I have 7 .agend/workflows files, along with progress.md, agents.md, and claude.md. Do you think the issue might be related to the claude.md file?

Should I rename it to gemini.md, or should I have both? I originally named it claude.md because I usually use the Claude Opus 4.6 model. Would it cause any issues if I just change the name to gemini.md, or if I add an extra gemini.md file next to it? Do you have any suggestions on how I should handle this?

1 Like

Thanks, same happened to me, removed the antigravity awesome skills package, and it fixed.

1 Like

i just deleted the whole .gemini folder in windows and re install it, seems to work now

I fixed it by running rm -rf ~/.gemini/antigravity/skills/ in my mac. Seems like some SKILLS cache issue. Be vary of installing global level SKILLS on your machine.

1 Like

I have a similar issue. However, for the work I let the antigravity do, after throwing the error message directly to the agent, it seems that the agent finds a way to avoid this error….. I am not sure whether your problem can be solved by this or not.

Good catch @AKova, kudos! :clap:

Renaming the skills folder to skills_old in ~\.gemini\antigravity\ worked for me as well.

Same. After seeing this thread I found the average of all the working fixes into one. I renamed the .gemini folder to something else(.gemini_old) and treat it as a backup folder now that I didnt have to copy. Once I reloaded Antigravity it re-created the .gemini folder and things are working fine. I have not checked yet but I have the AWESOME SKILLS github package installed globally on my pc so removing the direct antigravity path may not hinder being able to still use the agent skills. Good luck!

Muito Obrigado, resolveu meu problema imediatamente