Skip to content

Give the antigravity leg a workspace, and a way past the permission wall - #51

Merged
eirikb merged 1 commit into
mainfrom
feature/eirikb/antigravity-workspace-readonly
Aug 20, 2026
Merged

eirikb merged 1 commit into
mainfrom
feature/eirikb/antigravity-workspace-readonly

Conversation

@eirikb

@eirikb eirikb commented Aug 20, 2026

Copy link
Copy Markdown
Contributor

Antigravity ignores the process cwd. Print mode opens no workspace at all and works out of ~/.gemini/antigravity-cli/scratch instead, so the leg reviewed an empty dir - one run went looking for the repo with find $HOME -maxdepth 3. It takes the workspace as --add-dir, which command appends since it is the one that knows the repo. OsString and not String: a repo path need not be UTF-8, and to_string_lossy() hands antigravity a U+FFFD path that opens nothing.

Headless print mode soft-denies every tool that needs approval (since 1.1.3), which under the stock toolPermission: request-review is every shell command. Bare -p then exits 1 with "permission check failed", and under --sandbox it exits 0 having printed nothing at all - so since #50 made the prompt actually arrive, the leg has been trying to work and dying. --dangerously-skip-permissions clears the deny and --mode plan is what holds the tree: it refused both a straight "overwrite this file, do not plan" and the same thing routed through the terminal. Not --disable-slash-commands, though it fixes prompts that open with /: plan mode is built on that same expansion and the flag silently voids it, leaving skip-permissions on with nothing holding the tree.

Plan mode is also told by its own system prompt to put the findings in an artifact file and not repeat them in the reply, so stdout came back as "I have created a plan, please review it" with the review itself in a brain dir nothing reads. decorate_prompt appends a coda for that leg only, asking for the answer in the reply and for the workspace to be left alone.

Read-only there is a persona and not a sandbox, unlike every other leg, so stop claiming otherwise in agents.rs, README and SKILL.md, and check it instead: git status --porcelain before and after the fan-out, with a run note naming antigravity if the tree moved. Note an Ok leg that returned under 300 characters too - a placeholder answer used to render as an ordinary section, and the caller read a silent leg as one with nothing to add.

Antigravity ignores the process cwd. Print mode opens no workspace at
all and works out of ~/.gemini/antigravity-cli/scratch instead, so the
leg reviewed an empty dir - one run went looking for the repo with
`find $HOME -maxdepth 3`. It takes the workspace as `--add-dir`, which
`command` appends since it is the one that knows the repo. OsString and
not String: a repo path need not be UTF-8, and to_string_lossy() hands
antigravity a U+FFFD path that opens nothing.

Headless print mode soft-denies every tool that needs approval (since
1.1.3), which under the stock `toolPermission: request-review` is every
shell command. Bare `-p` then exits 1 with "permission check failed",
and under `--sandbox` it exits 0 having printed nothing at all - so
since #50 made the prompt actually arrive, the leg has been trying to
work and dying. `--dangerously-skip-permissions` clears the deny and
`--mode plan` is what holds the tree: it refused both a straight
"overwrite this file, do not plan" and the same thing routed through
the terminal. Not `--disable-slash-commands`, though it fixes prompts
that open with `/`: plan mode is built on that same expansion and the
flag silently voids it, leaving skip-permissions on with nothing
holding the tree.

Plan mode is also told by its own system prompt to put the findings in
an artifact file and not repeat them in the reply, so stdout came back
as "I have created a plan, please review it" with the review itself in
a brain dir nothing reads. decorate_prompt appends a coda for that leg
only, asking for the answer in the reply and for the workspace to be
left alone.

Read-only there is a persona and not a sandbox, unlike every other leg,
so stop claiming otherwise in agents.rs, README and SKILL.md, and check
it instead: `git status --porcelain` before and after the fan-out, with
a run note naming antigravity if the tree moved. Note an Ok leg that
returned under 300 characters too - a placeholder answer used to render
as an ordinary section, and the caller read a silent leg as one with
nothing to add.
@eirikb
eirikb merged commit 8db7ba2 into main Aug 20, 2026
1 check passed
@eirikb
eirikb deleted the feature/eirikb/antigravity-workspace-readonly branch August 20, 2026 07:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant