Metadata & Triage
- Type: Bug (
bug)
- Area:
apps/server, apps/web
- Estimated Fix Size:
size:M
- Impact: Major degradation or frequent failure
Before submitting
Steps to reproduce
- Run an agent turn where background commands or tasks run asynchronously (e.g., long-running test suites, typechecks, or background processes).
- Allow the background task to complete while the agent is active or between actions.
- Observe the chat timeline and assistant message bubble.
Expected behavior
- Background command outputs and exit codes should be captured within the tool execution card / work log.
- System notifications regarding task completion should be handled structurally without leaking internal protocol markers into the user-facing chat bubble.
- Subsequent tool calls should continue to group cleanly in the activity log.
Actual behavior
- The background task output breaks out of the tool/activity card and is dumped directly into the assistant's message bubble as raw plain text:
<system_message> Background task fb2c9a16-96f0-4cca-a8dc-6502f8f67d95/task-1183 has completed. Task exit code: 0 Execution output:
... [hundreds of lines of raw stdout / stderr / stack traces]
- This breaks the visual hierarchy and turn formatting: commands before it are collapsed into a summary card (
Ran 52 commands...), the massive unformatted terminal output fills the chat bubble, and subsequent tool calls (e.g. view_file, git, gh) appear detached below the leaked text.
Screenshots
1. Break in timeline formatting where <system_message> and command stdout/stderr dump into message text:

2. Raw stack traces continuing in the message body followed by detached tool call:

3. Full UI context showing subsequent tool actions resuming below the leaked text block:

Root Cause Analysis
- When background tasks complete, the runtime or harness delivers a notification containing
<system_message> Background task ... has completed. Task exit code: ... Execution output: ....
- Rather than being ingested as a structured tool result / task update or filtered out from the assistant text stream, this content ends up emitted as an
agent_message_chunk / ContentDelta.
- Consequently, internal harness delimiters (
<system_message>) and massive execution logs pollute the conversation view as assistant response text instead of being associated with the tool call or suppressed from the primary chat transcript.
- Tool grouping breaks as a result: tools executed before the leak stay grouped in the preceding card, while tools executed after the leak form a separate disconnected block below the message text.
Note on provider / model: This occurred while using Gemini 3.8 Flash (High) on the Antigravity provider. This could be specific to how the Antigravity harness/ACP integration delivers asynchronous task completion messages into the conversation stream, or a broader issue with how background task completion events are handled across providers.
Version or commit
Latest upstream main @ b1e223e2b (v0.0.41-nightly.20260912.1599)
Environment
Desktop / Web app, Antigravity provider, Gemini 3.8 Flash (High)
Metadata & Triage
bug)apps/server,apps/websize:MBefore submitting
Steps to reproduce
Expected behavior
Actual behavior
Ran 52 commands...), the massive unformatted terminal output fills the chat bubble, and subsequent tool calls (e.g.view_file,git,gh) appear detached below the leaked text.Screenshots
1. Break in timeline formatting where

<system_message>and command stdout/stderr dump into message text:2. Raw stack traces continuing in the message body followed by detached tool call:

3. Full UI context showing subsequent tool actions resuming below the leaked text block:

Root Cause Analysis
<system_message> Background task ... has completed. Task exit code: ... Execution output: ....agent_message_chunk/ContentDelta.<system_message>) and massive execution logs pollute the conversation view as assistant response text instead of being associated with the tool call or suppressed from the primary chat transcript.Version or commit
Latest upstream
main @ b1e223e2b(v0.0.41-nightly.20260912.1599)Environment
Desktop / Web app, Antigravity provider, Gemini 3.8 Flash (High)