[Bug]: Antigravity parent thread shows indefinite "Thinking" while waiting on a subagent or background task instead of a waiting/monitoring state
Before submitting
- [x] I searched existing issues and did not find a duplicate.
- [x] I included enough detail to reproduce or investigate the problem.
Area
apps/desktop
Steps to reproduce
- Open a thread in T3 Code using the Antigravity provider (1.5.14, e.g., Gemini 4 Neon (High)).
- Ask the agent to launch asynchronous background work that will wake it later — for example, spawning a native subagent (or starting a monitor / background task) and waiting for it to report back.
- Observe the parent thread UI after the parent sends its status message and pauses to wait for the reactive wakeup.
Expected behavior
After the parent's last message, the thread UI should clearly indicate that the parent is parked waiting on background work (e.g., showing Waiting on <subagent name> or Monitoring), matching how the integration with other harnesses displays background waits.
Actual behavior
While the parent is idle in the background waiting for the subagent, monitor, or background task to wake it, T3 Code indefinitely displays the active Thinking indicator below the parent's last message. It looks as though the parent model is actively thinking or stuck mid-generation rather than waiting on background work.
Impact
Minor bug or occasional failure
Version or commit
0.1.11
Environment
macOS 27, T3 Code 0.1.11, Antigravity 1.5.14, Gemini 4 Neon
Logs or stack traces
Screenshots, recordings, or supporting files
No response
Workaround
No response
Can confirm on T3 Code (Beta) 0.1.11 (macOS 27.2 build 26B123, arm64, Antigravity with Gemini 4 Neon):
- While the parent thread was parked waiting ~40s for a native
invoke_subagent(running a 20sscheduletimer) to report back, the parent thread displayed the activeThinkingindicator for the entire wait instead of a waiting/monitoring state.
Reproduced live on 0.1.12-nightly.20261121.5024 (server) / app 0.1.11, macOS, Antigravity (gemini-4-neon). A thread shows "Thinking" continuously for hours while completely idle between wakes.
State in statev2.sqlite: The run stays running because an earlier Run schedule dynamic tool call (a recurring cron schedule) stays running with no completedAt, even after ~190 subsequent assistant messages and tool calls in the same run have completed.
Root cause:
antigravityToolOutlivesPrompt(AntigravityProtocol.ts:56, from #39806) treats anyrunningRun scheduleas deferred background work, sohasDeferredBackgroundWork(provider-acp/src/server/adapter.ts) never finalizes the turn (and #40858'spostSettleCommandHoldexplicitly excludes schedules).- In the web UI,
MessagesTimeline.logic.ts:2383-2429only renders a dedicated status label for subagents (waitingOnSubagentsLabel); every other held run falls back to plain "Thinking".
Expected: Either finalize the turn once the prompt settles when only a recurring schedule is active (letting future cron wakes start/resume cleanly), or render a distinct "Waiting on schedule / background task" status instead of "Thinking".
Important additional impact beyond the UI "Thinking" label: because antigravityToolOutlivesPrompt / hasDeferredBackgroundWork keeps the run in running while a native schedule timer is active, it also starves the thread's incoming message queue:
- Incoming
t3_thread_send(mode: "auto") messages from worker/sibling threads pile up inqueuedinstead of waking the thread (in a real multi-thread orchestration session on T3 Code Nightly / Antigravitygemini-4-neon, 6 worker updates queued for 1–7 hours while consecutive 25-minutescheduletimers kept the same run open). - Normal user messages sent to the thread while idle between timer wakes also queue instead of delivering, forcing the user to manually Steer to get through.
- Cancelling the native
scheduletimer immediately restored instant delivery for both user messages andt3_thread_sendnotifications.
Because of this, a UI-only fix (renaming "Thinking" to "Waiting on schedule") will not resolve the functional bug — the run needs to settle out of running into an idle/waiting state once the prompt completes so incoming t3_thread_send and user messages deliver normally between timer wakes.