[Bug]: Antigravity provider aborts every turn when an OAuth-only remote MCP server is configured (initialize -> Unauthorized)

未关闭
#36,111 0 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看

维护者通常 1 天内回复

还没有人认领这个 Issue。

评估

难度
4/5
预计耗时
3-5 天
新手友好度
22/100
Issue 类型
缺陷
描述清晰度
基本清楚
活跃度
活跃
技术栈
nodejs, typescript

调研方向

Start in apps/server where the Antigravity ACP provider builds the private GEMINI_HOME and reads remote MCP entries from config/mcp_config.json, and check how it applies static headers versus the mcp_oauth_tokens.json store. Reproduce by adding an OAuth-only URL entry and confirming the initialize call gets a 401. Done means the token is presented, or the server is skipped and reported without aborting the turn.

由索引模型根据 Issue 内容生成。

描述

bug needs-triage
Before submitting
  • I searched existing issues and did not find a duplicate.
  • I included enough detail to reproduce or investigate the problem.
Area

apps/server

Steps to reproduce
  1. T3 Code (Nightly) 0.1.10-nightly.20261113.4630, macOS 27.2, Antigravity provider.
  2. In the provider profile config at /config/mcp_config.json add an OAuth-only remote server with no static headers:
    {"mcpServers":{"click-up-code-orange":{"url":"https://mcp.clickup.com/mcp"}}}
  3. Open a new Antigravity thread and send any message.
Expected behavior

The turn runs. A server that cannot authenticate is skipped or reported as degraded; it does not take down the harness.

Actual behavior

Every turn is aborted before the agent starts:
The MCP server 'click-up-code-orange' failed to initialize: calling "initialize": sending "initialize": Unauthorized. Fix the MCP server, or remove it from your configuration and start a new session, to continue.
Antigravity stopped this turn because of an error.

Impact

Blocks work completely

Version or commit

0.1.10-nightly.20261113.4630

Environment

macOS 27.2 (arm64), Node v26.11.1, Antigravity provider through the ACP bundle

Logs or stack traces
Not ClickUp-specific: any remote MCP server that relies on OAuth and carries no static headers fails the same way.

The ACP path authenticates remote MCP servers only through static headers in the server entry, so an OAuth-only entry is connected with no Authorization header and gets 401.

Credentials do exist and are valid: ~/.gemini/antigravity-cli/mcp_oauth_tokens.json holds an entry keyed by the exact server URL (https://mcp.clickup.com/mcp), and that access token returns 200 on a direct initialize to the same endpoint. The provider profile also has <profile>/antigravity-cli/mcp_oauth_tokens.json and <profile>/antigravity-acp/mcp_oauth_tokens.json pointing at that store, and the token is still not presented.

The same ~/.gemini config works in the standalone agy CLI (it has its own OAuth flow), so this looks specific to how the provider prepares and authenticates the private GEMINI_HOME.

One unauthenticated MCP server aborts the whole session, with no per-server isolation.

Related issues checked first:
- #30948 (Kiro threads cannot use OAuth MCP servers) is the same class of failure for another provider, not a duplicate: that one is driven by _kiro/secret/* capabilities, this one by the Antigravity ACP token store.
- #20097 and #20260 covered how a required MCP startup failure is reported in run status; both are closed and neither covers an OAuth-only entry.
Screenshots, recordings, or supporting files

No response

Workaround

Remove the OAuth-only server from /config/mcp_config.json, or give it a static Authorization: Bearer header. Turns then run normally.

主要语言
TypeScript
星标
24.8k
派生
6.4k
平均合并
59 分钟
30 天内合并 PR
418

环境准备

在 Codespaces 中打开

在浏览器里用你自己的 GitHub 账号启动这个项目的开发容器。

从这里开始

  1. 先读完整个 Issue,再读项目的贡献指南。
  2. 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
  3. Fork 仓库,在一个分支上完成修改。
  4. 提交 Pull Request,并在描述里引用这个 Issue 编号。

pingdotgg/t3code 的其他 Issue

查看 pingdotgg/t3code 的全部 Issue

相似的 Issue

更多 TypeScript Issue

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。