[Bug]: Antigravity ACP's 3m0s MCP tool timeout aborts blocking request_secret calls and cancels the card 7 minutes early
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/server
Steps to reproduce
- Start a thread using the Antigravity ACP provider (
gemini-4-neon) on T3 Code0.1.11(reproduces identically on both local macOS threads and remote linked Linux threads). - Trigger a
request_secretMCP tool call with either the default timeout (10m) or an explicittimeoutMsgreater than180000(e.g.,600000). - Leave the secret card unanswered for 3 minutes (for example, while looking at another thread).
Expected behavior
The request_secret card should remain open and answerable for T3 Code's configured timeout (DEFAULT_SECRET_REQUEST_TIMEOUT_MS = 10 * 60 * 1_000, up to MAX_SECRET_REQUEST_TIMEOUT_MS = 60 * 60 * 1_000 in apps/server/src/mcp/OrchestratorMcpService.ts), and if unanswered when that timeout elapses, the tool should return { status: "timed_out" }.
Actual behavior
At exactly 3 minutes (180s), Antigravity ACP's Go MCP client aborts the blocking POST /mcp (tools/call request_secret) request with context deadline exceeded.
On the T3 Code server side:
OrchestratorMcpService.requestSecretholds the single HTTPPOST /mcpcall open while polling every500msand registersEffect.onExit((exit) => (Exit.isSuccess(exit) ? Effect.void : closeCard)).- When Antigravity cancels the HTTP request at
180s, T3 Code interrupts thetools/call request_secretfiber (durationMs: ~180019–180031), immediately runscloseCard, and dispatchessecret_request.recordwithsecretStatus: "cancelled"("Request ended"). - The secret card vanishes from the UI 7 minutes before the intended 10-minute default timeout,
timeoutMs > 180000is silently ineffective, and the agent receives an MCP transport error instead of{ status: "timed_out" }. - Answering the same card within
< 3m0ssucceeds normally (secret_request.status: "saved").
(Note: OrchestratorMcpService.ts already caps t3_thread_wait at 30–45 s with the comment // Return recoverable handles before common MCP client timeouts expire, and t3_environment_link returns pending asynchronously rather than holding POST /mcp open for 10+ minutes. A similar async / turn-waking or keepalive pattern would avoid MCP client call deadlines for request_secret.)
Impact
Major degradation or frequent failure
Version or commit
0.1.11
Environment
- macOS (local host & desktop client): T3 Code (Beta)
0.1.11, macOS26.5.1(arm64), Antigravity ACP1.5.13, modelgemini-4-neon - Linux (remote linked host):
t3 v0.1.11, Ubuntu26.04.1 LTS(x64), Antigravity CLI (agy)1.5.14, modelgemini-4-neon
Reproduced across 6 runs on both hosts (local macOS and remote linked Linux).
Logs or stack traces
# Antigravity ACP transcript (identical on macOS 1.5.13 and Linux 1.5.14):
Encountered error in step execution: MCP tool call to server "t3-code" timed out after 3m0s: context deadline exceeded
# T3 Code server.trace.ndjson (sanitized, identical pattern on macOS and Linux):
{"type":"effect-span","name":"tools/call request_secret","durationMs":180024.75,"attributes":{"mcp.method.name":"tools/call","gen_ai.tool.name":"request_secret"},"exit":{"_tag":"Interrupted","cause":"InterruptError: All fibers interrupted without error"}}
{"type":"effect-span","name":"orchestrationV2.dispatch.once","attributes":{"orchestration_v2.command_type":"secret_request.record","orchestration_v2.command_id":"command:mcp:<redacted>:secret-cancelled:<redacted>"}}
Workaround
Stay on the active thread and submit the request_secret card within 3 minutes of the agent opening it (or ask the agent to reopen the card once actively viewing the thread).