Skip to content

fix: check current Antigravity composer for terminal readiness - #21613

Closed
nwparker wants to merge 5 commits into
nwparker/agy-gemini-issuesfrom
nwparker/agy-visible-readiness
Closed

nwparker wants to merge 5 commits into
nwparker/agy-gemini-issuesfrom
nwparker/agy-visible-readiness

Conversation

@nwparker

@nwparker nwparker commented Sep 19, 2026 •

Copy link
Copy Markdown
Contributor
Files Added Deleted Net
Test 17 $\color{#1a7f37}{\Huge{\mathbf{+}}}$​546 $\color{#cf222e}{\Huge{\mathbf{−}}}$​84 $\color{#1a7f37}{\Huge{\mathbf{+}}}$​462
Prod 11 $\color{#1a7f37}{\Huge{\mathbf{+}}}$​308 $\color{#cf222e}{\Huge{\mathbf{−}}}$​34 $\color{#1a7f37}{\Huge{\mathbf{+}}}$​274

ELI5

Orca should send a task only when Antigravity’s input box is empty and ready. Previously it could remember a trust dialog that had already disappeared, or mistake a > inside unfinished input for a ready prompt. This change checks the current input box and shortcut footer instead.

What Changed

Antigravity readiness now uses the current terminal screen for immediate waits, polling, title callbacks, and the queued-message delivery gate, as well as the adopted-terminal fallback. It recognizes empty default, Plan and accept-edits composers and rejects the recorded drafts, dialogs and working screens.

Screen reads reuse the existing execution-host terminal snapshots and pending-read deduplication. Cached results are rejected after new output, a process generation change, or queued headless writes/reflow. A host marked unverifiable cannot satisfy Antigravity readiness from a cached screen; the adopted-screen fallback also rechecks host contact after its asynchronous read. Other agents retain their existing ordinary readiness behavior.

Why

Antigravity redraws its terminal with cursor movements. A plain output history can retain dismissed dialogs and draft continuation rows. Checking the rendered composer frame plus shortcut footer handles the recorded states without depending on model names or mistaking placeholder wording for user input.

Linked Issue

Refs #21110, #15838, #13854. Related work: #21231 and #20027.

Stacked on #21606 to keep the verification worktree; the diff against its base is readiness-only. This remains draft pending broader worker-start and remote validation.

Visual Proof

Verified the installed agy (banner 1.2.7) in the rebuilt branch using hidden Electron CDP and a temporary folder workspace.

Before: the empty composer returned agent-trust-workspace after trust was accepted; after restarting the app, the same daemon terminal timed out instead. The previously attached empty-Plan capture shows the input state:
Empty Plan composer before integration

After: that terminal returns satisfied: true. Typing the exact Plan hint makes a 4.5-second wait time out; clearing it returns satisfied: true again. This screenshot was inspected alongside the actual RPC result:
Empty composer after integration

The same words typed as an unsent draft remove the shortcut footer:
Typed Plan hint

A further live text-and-Enter submission reached installed agy, which attempted generation and returned HTTP 401 ACCESS_TOKEN_TYPE_UNSUPPORTED. The next readiness wait succeeded at its empty composer:
Live agy request and authentication failure

This proves ordinary input delivery and local composer readiness, not successful generation or end-to-end worker delivery. The public RPC's guarded prompt route currently supports Claude/Codex only; setting agentPrompt did not make this agy check a guarded submission. The test app also logged a renderer replay-guard warning after restart; the subsequent typed/cleared states rendered correctly, but that separate recovery behavior was not fixed here.

Testing

  • Real installed agy in hidden Orca: empty composer ready, typed draft refused, cleared composer ready.
  • Captured-screen and adopted-fallback tests: 23 passed, including a snapshot arriving after host contact was lost.
  • Ordinary transcript wait/delivery regressions: 12 passed, including dismissed trust, new-output/reflow invalidation, queued-delivery retry, and refusal of cached readiness after the host becomes unverifiable.
  • Existing poll, delivery/quiescence and name-only readiness suites: 25 passed.
  • Node typecheck, focused lint, changed-code quality gate.
  • Successful authenticated worker turn, real SSH/Windows execution, reconnection snapshot freshness, narrow wrapped layouts and scrolled-away banners.

Review

Agent skill upstream boundary

  • No upstream skill-installer material copied.

Notes

No wire fields, credentials, execution-host selection or agent-status store changes. The internal snapshot cache tracks screen freshness; it does not publish agent status. Installed agy generation currently fails with HTTP 401, so this PR does not claim successful generation.

Checklist

  • ELI5, mechanism and rationale documented
  • Real rendered before/after evidence attached
  • Automated readiness regressions and static checks
  • Broader worker-start and remote validation complete

@nwparker nwparker changed the title Fix Antigravity readiness in adopted-terminal screen checks fix: check current Antigravity composer for terminal readiness Sep 19, 2026
@nwparker

Copy link
Copy Markdown
Contributor Author

Full-stack verification update at e783bc9b67b: ORCA_BACKGROUND_LAUNCH=1 pnpm build passes, including typecheck, relay/CLI, desktop renderer/preload/main, web/mobile bundles, and macOS native components. Restarted the hidden app and verified its identity is nwparker/agy-history-workspace in this worktree.

The real long-title agy session now renders under Workspace scope with its recovered folder metadata. Rendered evidence and two remaining adjacent gaps (/tmp versus /private/tmp matching, and “Unavailable worktree” on a folder session) are documented in #21638. This validates the accumulated build, not authenticated model generation or other platforms. No drafts promoted or issues closed.

@nwparker

Copy link
Copy Markdown
Contributor Author

CI follow-up: commit 7e85ea6 corrects the seven readiness failures reported by the full runtime suite. No production detector was relaxed.

ELI5: some tests still supplied a made-up screen, and others replayed the agent quitting before asking whether it was ready. The tests now use the real captured screen at its recorded size and distinguish the live screen from shutdown.

  • Five runtime cases replay the installed-agy 1.2.7 capture at 120×40; their timeout now covers the 2-second idle poll and asynchronous rendering.
  • The transcript suite asserts the correct result directly instead of pinning historical bugs, including model-picker rejection.
  • Three older captures include keyboard-reset/clear-screen shutdown bytes. Live-phase assertions stop before that recorded trailer; separate full-file checks reject the screen after shutdown erases its footer. Capture files are unchanged.
  • Refusal tests now run beyond the first idle poll, avoiding a false pass before the snapshot is examined.

Validation: full Orca runtime suite plus four agy readiness suites: 1,345 passed, 11 skipped. The final longer-refusal transcript run: 20 passed, 10 skipped (missing captures remain explicitly skipped). Node typecheck, changed-code-quality gate, and commit lint/format hooks pass. Existing live-app screenshots in this PR remain the behavior proof; this follow-up changes tests and documentation only.

The correction is being propagated through the dependent drafts. Fresh CI results are still required; this is not a merge recommendation.

@nwparker

Copy link
Copy Markdown
Contributor Author

Independent verification update:

  • Installed agy 1.2.7 responded with the exact sentinel AGY_READINESS_LIVE_OK.
  • Readiness and transcript suites: 100 passed, 10 skipped across 5 test files.
  • The existing branch CI run 35434508156 is green across all 8 test shards, typecheck, static analysis, and both packages.

The visible composer behavior is verified for the captured macOS/local path. I recommend keeping this PR draft until the documented gaps are closed: authenticated worker delivery, Windows/SSH execution, reconnection freshness, narrow wrapped layouts, and scrolled-away banners. No merge recommendation yet for those broader scopes.

@nwparker

Copy link
Copy Markdown
Contributor Author

Independent verification (2026-09-20):

  • Readiness-focused tests: 68 passed, 10 skipped across five files covering ordinary waits, visible composer, transcript fixtures, visible waits, and generation compatibility.
  • pnpm tc:node passed.
  • pnpm run check:code-quality:changed origin/main passed with 0 new findings across 25 changed files.
  • Existing full CI run 35434508156 is green across all eight test shards, typecheck, static analysis, and macOS/Windows packages.
  • New live evidence: authenticated agy 1.2.7 interactive TUI accepted a 101-line prompt and completed with an exact sentinel response. This supports the working-turn path, but it is not a rendered Orca composer screenshot and does not prove reconnect, SSH, WSL, or paired-runtime behavior.

Verdict: keep draft. The local readiness implementation is verified and the authenticated worker path now has supporting live evidence, but the PR’s remaining cross-host/reconnection/rendered-layout gaps are still real. No merge performed.

@nwparker

Copy link
Copy Markdown
Contributor Author

Orca host-list / m4air exercise (2026-09-21)

orca host list --json found connected targets: local macOS, SSH openclaw (connected Linux), and paired environments awin, m4air, and win-lowspec.

Using orca against the live m4air environment, I created a disposable worktree from the PR base, fetched PR head 7e85ea643e, and ran the readiness suites through an Orca-managed terminal on native macOS:

  • antigravity-visible-composer.test.ts: 15 passed
  • antigravity-visible-wait.test.ts: 11 passed
  • antigravity-readiness-transcripts.test.ts: 30 passed, 10 intentionally skipped because captures are absent
  • antigravity-ordinary-wait.test.ts: 12 passed
  • Total: 58 passed, 10 skipped

The tests exercised local and SSH-host readiness fixtures, multiline drafts, model-picker dialogs, busy turns, host-loss invalidation, reflow invalidation, and queued-delivery rechecks. The m4air shell reports Darwin arm64 but has no agy binary installed, so this was a transcript/runtime-harness exercise rather than a live authenticated agy generation. The disposable worktree is being removed after the run.

The broader Windows/SSH/WSL/reconnect/rendered-layout gaps remain real; this lowers risk for the tested readiness implementation but does not justify merging the draft as universal cross-host proof.

@nwparker

Copy link
Copy Markdown
Contributor Author

Fresh m4air authenticated check (2026-09-21)

Using orca against a new m4air Orca-managed terminal started as a zsh login shell:

  • .zshrc environment check: GEMINI_API_KEY_PRESENT (value not printed)
  • agy path: /Users/m4air/.local/bin/agy
  • agy version: 1.2.7
  • Authenticated print probe returned the exact sentinel AGY_M4AIR_AUTH_OK

This confirms the new terminal sees the exported .zshrc key without restarting the Orca daemon. It is live authentication evidence for the host, not a rendered readiness screenshot or a full worker-turn proof for this PR.

@nwparker
nwparker deleted the branch nwparker/agy-gemini-issues September 21, 2026 05:12
@nwparker nwparker closed this Sep 21, 2026
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