What I found (source reading of the shipped ACP server, not a live transcript)
I run Antigravity headlessly through its ACP server (agy_acp_server, agentInfo.version agy_acp_server_1.1.1, Linux) with a relocated GEMINI_HOME. While wiring a PreToolUse hook that rewrites shell commands, I read the Python sources shipped in the release archive (acp_server/hooks.py, acp_server/paths.py) and found two gaps against the hooks documentation (antigravity.google/docs/hooks). The same two files in the 1.4.1 Linux x86_64 archive (agy-acp-server-1.4.1-linux-x86_64.zip, sha256 2e37012c…871384) are byte-identical to 1.1.1’s, so both releases are affected:
-
overwriteis dropped. The external PreToolUse handler maps the hook’s JSON output to allow/deny only (allowTool,decision,reason/denyReason).overwriteandpermissionOverridesare never read, and the hook result is never turned intoHookResult.modified_args, although the SDK’s hook router already forwardsmodified_arguments_jsonto the harness. So a hook answering{"decision":"allow","overwrite":{"CommandLine":"rtk git status"}}leaves the originalCommandLinein place. I confirmed this by running the shipped handler function on that exact output in isolation (result:{"allow": true}, args unchanged); I have not yet spent a live ACP session on it. -
Only
config/hooks.jsonis read.paths.pyresolves the global hooks file as<GEMINI_HOME>/config/hooks.json, and the loader adds trusted workspace hook files. There is no traversal of<GEMINI_HOME>/config/plugins/<name>/hooks.jsonin the ACP server’s loader, so a plugin bundle that ships ahooks.json(for example the onertk init -g --agent antigravitywrites) is inert through ACP. The Go harness binary bundled with the release does carry strings aboutplugins/<name>/hooks.json, but under ACP its hooks appear to be dispatched back through the Python server, and I did not exercise that path.
Why it matters
Tools like rtk rely on overwrite for Antigravity. Through ACP — the path external clients such as acpx, Zed or T3 use — such hooks install cleanly and do nothing, with no error or log line telling the user why.
Ask
- Map PreToolUse
overwritetoHookResult.modified_argsin the ACP server (the SDK side already carries it), and document whetherpermissionOverridesis honoured there. - Load
config/plugins/*/hooks.jsonin the ACP server the way the documented plugin model implies, or document that ACP reads onlyconfig/hooks.json.
I can share the minimal hook and the isolated reproduction if useful.
Related:
- Do Antigravity IDE / 2.0 actually execute plugin hooks (PreToolUse/PostToolUse), or is that CLI-only right now?
- PreToolHookResult overwrite is broken under toolPermission=request-review and Bug: PreToolHookResult overwrite is broken under toolPermission=request-review · Issue #575 · google-antigravity/antigravity-cli · GitHub (CLI, different mechanism)
(Drafted with Claude from my own reading and tests, reviewed before posting; the voice and decisions are mine.)
– Claude