Repository navigation
fix(antigravity): show command approvals in Chat - #21776
Conversation
|
Live Windows verification at The exact rebuilt app accepted a prompt through Chat and agy reached the command approval menu, but Chat still showed no card. The canonical row remained working, with a real terminal handle and hook observation. No persistent command allowance was selected. The earlier 66 tests and static checks remain valid within their scope; they do not prove the live fix. |
|
Independent verification update:
Scoped verdict: Approve with #21660, in stack order. The PR’s awin visual proof covers the real Allow/Deny card, 204 ms waiting-state clear, completion, and cancellation. WSL/paired-runtime and narrow-layout coverage remain open. |
|
Independent verification (2026-09-20):
Verdict: approve with #21660 in stack order for command-approval publication and clearing. WSL/paired-runtime and narrow-layout coverage remain open. No merge performed. |
ELI5 / evidence / trade-offs auditELI5: Orca asks for permission before a chat action that needs approval, instead of silently doing it. Proof: Permission/transcript tests and sanitized Chat proof pass; no additional screenshot was needed for this incremental approval change. User-facing trade-off: Users may see an extra approval prompt for protected actions. This note scopes the claim to the evidence above; it does not claim untested remote, SSH, WSL, or vendor combinations. |
… startup (#21770) * fix(antigravity): retain handoffs through slow Windows PTY binding * fix(antigravity): show command approvals in Chat (#21776) * fix(antigravity): publish captured command approvals to Chat * fix(antigravity): bind native hook screen evidence to runtime terminal * fix(antigravity): settle cancelled approvals at the idle composer * fix(antigravity): clear approval while accepted commands run
There was a problem hiding this comment.
✅ No new issues found.
Reviewed changes
- Command-approval screen classifier — adds
isAntigravityCommandApprovalScreen, an exact match for the captured four-choiceRun this command?dialog, and wires it intoclassifyTerminalScreenReadinessso a pending approval now reportsagent-approval-promptinstead of lettingtui-idletime out. - Host-owned permission publisher —
AntigravityScreenPermissionPublishercoalesces per-PTY screen reads, gates on generation/sequence/liveness and host contact, and publishes either the detected command or a positive working/idle clear. - Store ingest —
AgentHookServer.ingestAntigravityScreenPermissionrejects late revisions, other terminals and providers, restored rows, and direct-SSH rows, then writes the existing approval envelope throughapplyNormalizedStatusas aprocessobservation; both the desktop and headless hosts wire the new dependency. - Evidence and tests — four native Windows agy 1.2.7 transcript captures with sidecars, plus unit tests covering publication, coalescing, terminal/SSH/dead-revision rejection, and the readiness classification of each capture.
I verified the new and neighboring Antigravity suites (32 tests) pass, pnpm run typecheck:node is clean, and oxlint reports no issues on the new/changed files. The changed-code quality gate could not run because its merge-base step targets origin/main while this PR is stacked on nwparker/agy-windows-spawn-budget.
Noting for the record, not as a blocker: the screen rule is an exact-string match against a single 120×40 native Windows capture, so narrower widths, other platforms, WSL, and paired-runtime Chat remain unverified — a CLI wording or layout change would silently stop surfacing the card. The PR body already scopes this.
DeepSeek Flash (free via Pullfrog for OSS) | 𝕏
* feat(agents): deprecate Gemini CLI setup in favor of Antigravity * fix(i18n): register Gemini deprecation copy * fix(i18n): refresh runtime catalog after legacy setup labels * test(agents): expect legacy Gemini label in skill coverage * fix(antigravity): preserve continuation through slow Windows terminal startup (#21770) * fix(antigravity): retain handoffs through slow Windows PTY binding * fix(antigravity): show command approvals in Chat (#21776) * fix(antigravity): publish captured command approvals to Chat * fix(antigravity): bind native hook screen evidence to runtime terminal * fix(antigravity): settle cancelled approvals at the idle composer * fix(antigravity): clear approval while accepted commands run
Recover scoped transcript, terminal approvals, and WSL support on current main. Keep hook-server authority, captured-grid rules, quiescence, and current journals. Negotiate Antigravity reads and subscriptions on desktop, web, and mobile. Credits #15773, #21660, #21776, and #24141. Co-authored-by: haoliangli <haoliangli@users.noreply.github.com> Co-authored-by: sojiro-o <53679703+sojiro-o@users.noreply.github.com>

ELI5
Merge verdict: approve the scoped fix with #21660, in stack order. Final head
646935991b6passes live Windows Allow/Deny verification and all latest CI checks. This PR remains a draft; no merge or draft promotion was performed.When Antigravity asks permission to run a command, Chat can look busy forever because the question is hidden in the terminal. This change recognizes the real command menu and shows the existing Allow/Deny card in Chat.
What Changed
The execution host reads the current terminal screen and publishes the pending approval through the existing agent-status store. An unchanged approval is coalesced. Captured working screens clear an accepted approval to working; cancellation clears the pending tool and returns to idle once the current screen proves the empty composer is back. Native-hook rows use the runtime’s verified terminal binding, since hook payloads do not carry a terminal handle. The update requires the same terminal and status revision, and rejects outdated snapshots or lost host contact. Desktop and headless hosts use the same path.
Why
Antigravity emits a pre-tool hook even for already-allowed commands, so treating every tool start as an approval would be wrong. The new rule is based on raw captures of pending approval, Escape cancellation, one-time acceptance with
1, foreground generation, and an approved Windows background command still running. Publishing at the host keeps Chat and status readers on the same source.Linked Issue
Follow-up to #21660 and #20157. Stacked on #21770. Does not close the overall migration issue #17345.
Visual Proof
Before: actual Windows Chat approval gap.
Before: Chat showed only the composer while the terminal waited for command approval.
After: the real Windows Chat view shows the existing Allow/Deny card and the sidebar reports Needs permission.
At
646935991b6, clicking Allow for an eight-second command clears canonical waiting status and the sidebar’s Needs permission state within 204 ms. The card disappears immediately, status remains working during execution, and the exact final reply appears with Done at 14.3 seconds. Before this follow-up, waiting remained stale for 9.3 seconds. On the same final build, clicking Deny interrupts a second command, removes the approval and pending tool, and returns the sidebar to idle. The actual terminal confirms Interrupted and an empty composer.Testing
pnpm tc, changed-code quality, focused lint, secret scans and commit hooks pass.1acceptance.646935991b6; clean Windows Electron/Vite build passes. The final follow-up also passes Node typecheck and changed-code quality.Review
Direct SSH remains terminal-only; a client does not publish screen-inferred state for an SSH mirror. Paired runtimes run the producer on their execution host. No wire opcode, required wire field, polling interval, renderer status store or automatic approval is added. Existing mobile presence-lock and send behavior remain in place. Folder workspaces use the same pane/terminal identities.
Agent skill upstream boundary
Notes
Remaining platform coverage: narrower terminal widths, live WSL and paired-runtime Chat. Direct-SSH Chat remains unsupported. All latest final-head CI checks pass, including all eight test shards, static analysis, typecheck, managed hooks, and macOS/Windows packaging. Temporary Windows verification app and terminal are closed; all 18 global hook files and the original hook configuration are unchanged. The generic approval card's
1key is verified only against native Windows agy 1.2.7. This PR does not implement multi-account support or direct-SSH Chat.Checklist