Skip to content

fix(antigravity): Auto no longer asks before reads that Supervised allows - #40303

Open
dedelmann wants to merge 2 commits into
pingdotgg:mainfrom
dedelmann:fix/antigravity-auto-reads
Open

dedelmann wants to merge 2 commits into
pingdotgg:mainfrom
dedelmann:fix/antigravity-auto-reads

Conversation

@dedelmann

Copy link
Copy Markdown

Problem

In an Antigravity thread in Auto, every file read outside the thread's working directory shows an approval card, while Supervised and Auto-accept edits allow the same reads. One delegated review subagent, running in an Auto thread whose project wasn't the repo under review, raised 32 cards, all Read <file>; the first held the turn for about 7.5 minutes. Seen on T3 Code 0.1.12-nightly.20261120.4994, agy 1.5.13, macOS arm64, Google sign-in.

Change

antigravityPermissionDisposition answered every non-denied Auto request with ask, on the premise that agy's Auto has already reviewed what it sends. For file reads it hasn't: in that session each of the 32 reads logs agy_tool_safety FINISHED: triggered=false, reason="allowed_tool" and sir_flash_lite SKIPPED, so agy's Auto review model never looked at them. agy sends the request because the path is outside its workspace (capture below), the same request it sends in every mode. In the same session, git status/git diff and git grep on that repo went through agy's review, and none of them reached T3 as a permission request.

Read kinds (read, search, think, via the shared isAcpReadKind, now exported) now follow the shared policy in Auto, as in every other mode. Every other kind agy sends in Auto still asks (execute, edit/delete/move, fetch, other, missing), and sandbox denials still deny.

Scope

Fixes #40127. This narrows review finding R1-F3 of #39378 to non-read requests. R1-F3 made read-kind requests ask in Auto, on the premise that anything agy sends in Auto is an escalation its review refused. The log above shows that isn't true for reads, and #13584 already decided that read-kind permission requests follow the sandbox and never ask. Grok and fx keep ask-everything in Auto: their Auto prompts are classifier refusals, and Grok never sends read requests (#13584).

The same change closes the gap CodeRabbit flagged on #39378: an Auto thread on an account without native Auto shows Supervised, but still asked for reads that Supervised allows.

#39822 edits the same return line for T3 MCP tools. The two compose (deny, then T3 MCP allow, then reads follow the shared policy, then ask); I'll rebase on it if it lands first.

This keeps the fix to the existing modes. Whether Auto should also allow non-workspace access more broadly could instead be a per-provider setting: agy already has allowNonWorkspaceAccess in its settings.json, and with it set agy sends no request for these reads at all, but T3 rewrites that file on every launch. That would be a separate change, so it isn't part of this PR.

Verification

  • The Auto table in AntigravityAcpSupport.test.ts now expects allow for read and ask for execute and fetch. The read row fails on main and passes with the fix; the sandbox-denial test still passes. vp run check:changed passes: format, lint, knip, typecheck (14 packages), tests.
  • Real app, before and after: an isolated dev server (vp run dev --no-seed) with agy 1.5.13 and a Google sign-in (native Auto offered), Gemini 3.8 Flash, permission mode Auto, project demo/app, prompt: "Use your file viewing tool (not a shell command) to read ../shared/notes.txt and tell me the release codename."
    • main: the Read …/demo/shared/notes.txt row waits for approval ("Waiting for approval · Allow once · Deny · More"), and the thread shows Approval.
      main: the read waits for approval in Auto
    • This branch: no prompt; the agent reads the file and answers "BLUE HERON".
      this branch: no prompt, the agent answers
      (Home path and machine name blacked out.)
  • What agy sends, captured from agy acp 1.5.13 with the same sign-in: session/new offers default, accept-edits, auto, plan; session/set_mode to auto returns {}; a file-tool read outside the cwd then arrives as (trimmed):
    {"toolCall": {"name": "read_file", "kind": "read", "status": "pending",
      "locations": [{"path": "/Users/<me>/<other-repo>/README.md"}]},
     "options": [{"optionId": "allow", "kind": "allow_once"}, {"optionId": "deny", "kind": "reject_once"}]}
    The test's read row uses a request of the same kind.
  • An independent comment on [Bug]: Antigravity Auto asks before reads that every other runtime mode allows #40127 reports the same cards on Linux x64 and the same fix working there.
  • Not checked: search- or think-kind requests live (I haven't seen agy send them), and a session without native Auto.

Fix designed and first drafted with Gemini 4 Neon (Antigravity in T3 Code); final code and tests written with Claude Opus 5.5 in Claude Code (T3 Code). Reviewed with Claude Fable 5.2, Claude Opus 5.5 and Gemini 4 Neon.

🤖 Generated with Claude Code

…lows

In Auto, antigravityPermissionDisposition answered every non-denied request
with "ask" on the premise that agy's Auto had already reviewed it. agy's
Auto reviews commands, not file reads: it still sends a read-kind
permission request for any path outside its workspace, so every such read
became an approval card, although Supervised and Auto-accept edits allow
the same request. Read kinds now follow the shared policy; everything else
in Auto still asks, and sandbox denials still deny.

Fixes pingdotgg#40127

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@github-actions github-actions Bot added vouch:unvouched Author is not yet trusted in the VOUCHED list. size:S 10-29 changed lines (additions + deletions). labels Nov 21, 2026
@coderabbitai

coderabbitai Bot commented Nov 21, 2026 •

Copy link
Copy Markdown
Contributor

Explain Change →

No actionable comments were generated in the recent review.

Walkthrough

Antigravity Auto-mode permission handling now preserves the shared policy disposition for ACP read kinds. Non-read requests that are not denied still require approval. The shared read-kind predicate is exported, and the permission test covers execute, fetch, and read requests.

Changes: Antigravity Auto permissions

Layer / File(s) Summary
Read-kind permission handling
packages/provider-acp/src/server/clientPolicy.ts, apps/server/src/provider/acp/AntigravityAcpSupport.ts, apps/server/src/provider/acp/AntigravityAcpSupport.test.ts
isAcpReadKind is exported and used to preserve the shared disposition for reads in Auto mode. Other non-denied requests still receive "ask". The test expects "allow" for reads and "ask" for execute and fetch requests.

Estimated code review effort: 2 (Simple) | ~10 minutes

Change: Bug fix · Severity of issue fixed: Medium

Suggested reviewers: mkantenko, juliusmarminge

Merge Risk: Minimal · up to 45753

Merge Risk: ⚪ Minimal · up to 45753

Antigravity Auto will stop prompting for file reads that other modes already allow, and other request kinds still ask. No actionable merge risk remains.

Pre-merge checks: Passed 4

Check name Status Explanation
Title check Passed The title names the main change: Antigravity Auto mode no longer prompts for reads that Supervised mode allows. The raw summary shows the code change matches this: read-kind requests in Auto now follo…
Description check Passed The description follows the template closely. It has Problem, Change, Scope, and Verification sections, with a conventional-style context and the agent attribution line. The Problem section gives expe…
Linked Issues check Passed Issue #40127 requires that Antigravity Auto stop prompting for read-kind permission requests, as Supervised and Auto-accept edits already do, and that read requests follow the shared policy (#13584). …
Out of Scope Changes check Passed The reviewed source change is narrow. It changes one condition in antigravityPermissionDisposition and exports the existing isAcpReadKind helper, which the fix needs. The other changes described i…
Full details: Title check

Explanation

The title names the main change: Antigravity Auto mode no longer prompts for reads that Supervised mode allows. The raw summary shows the code change matches this: read-kind requests in Auto now follow the shared policy, while other kinds still ask. The title uses the conventional commit form and is specific enough for a teammate scanning history. It is 73 characters, slightly over typical length but still readable.

Full details: Description check

Explanation

The description follows the template closely. It has Problem, Change, Scope, and Verification sections, with a conventional-style context and the agent attribution line. The Problem section gives expected and actual behavior with environment details. The Change section explains the fix and why other request kinds still ask. The Scope section links issue #40127, explains why the change is a bug fix and not a feature, and names related PRs. The Verification section lists focused tests, a real-app before/after comparison with screenshots, the captured request payload, and what was not checked. The description is thorough and mostly complete.

Full details: Linked Issues check

Explanation

Issue #40127 requires that Antigravity Auto stop prompting for read-kind permission requests, as Supervised and Auto-accept edits already do, and that read requests follow the shared policy (#13584). At head, antigravityPermissionDisposition in apps/server/src/provider/acp/AntigravityAcpSupport.ts returns ask in Auto only when the disposition is not deny and isAcpReadKind(request.toolCall.kind ?? "other") is false. Read-kind requests therefore keep the shared acpPermissionDisposition result. In packages/provider-acp/src/server/clientPolicy.ts, acpReadDisposition returns allow for sandbox types undefined, readOnly, workspaceWrite, dangerFullAccess, and externalSandbox, and deny otherwise. Reads outside the workspace are therefore allowed without a card. The sandbox-denial path still denies. Missing kinds map to other and still ask. isAcpReadKind is exported, as the fix requires. The test expectations in AntigravityAcpSupport.test.ts were not read directly because the test-file diff was unavailable. The PR description reports that the read row fails on main and passes with the fix. Live search/think requests were not observed, but isAcpReadKind covers them under the same shared rule. The requirement is met in code.

Full details: Out of Scope Changes check

Explanation

The reviewed source change is narrow. It changes one condition in antigravityPermissionDisposition and exports the existing isAcpReadKind helper, which the fix needs. The other changes described in the PR are the test expectations in AntigravityAcpSupport.test.ts for read, execute, and fetch, which directly verify this fix. The PR explicitly leaves broader non-workspace access settings and MCP handling (#39822) out of scope, and the diff does not add either. No unrelated change was found in the inspected hunks. The clientPolicy.ts diff could not be read, so its change is taken from the supplied summary: an export-only change to isAcpReadKind, which the current file content confirms.

Finishing Touches

Generate unit tests (beta)

  • Create a new PR
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts
Recent review info

Run configuration

Commits

Reviewing files that changed from the base of the PR and between c1464d6 and da8d12b.

Files selected for processing: 3

  • apps/server/src/provider/acp/AntigravityAcpSupport.test.ts
  • apps/server/src/provider/acp/AntigravityAcpSupport.ts
  • packages/provider-acp/src/server/clientPolicy.ts

Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 9 remain after this review.

@juliusmarminge juliusmarminge added the takeover:in-progress A takeover lead is working on this PR label Nov 21, 2026

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size:S 10-29 changed lines (additions + deletions). takeover:in-progress A takeover lead is working on this PR vouch:unvouched Author is not yet trusted in the VOUCHED list.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug]: Antigravity Auto asks before reads that every other runtime mode allows

2 participants