Repository navigation
feat(cli): add Goose (AAIF) as the 16th CLI vendor - #524
Closed
nt-nerdtechnic wants to merge 6 commits into
Closed
nt-nerdtechnic wants to merge 6 commits into
nt-nerdtechnic wants to merge 6 commits into
Conversation
Goose keeps every session in one SQLite db (schema v17). The reader reads it like OpenCode's: kickoff-marker binding on user rows of top-level interactive sessions, tokens from usage_ledger (input already includes cache), and a text-only agent-visible assistant row as the turn end. Resume is `goose session -r --session-id <id>` with a db preflight. Facts recorded live from goose 1.55.0 in a scratch HOME/GOOSE_PATH_ROOT against a loopback mock endpoint (no account, keyring and telemetry off): the macOS data dir is the XDG one, `-n` names are not unique, text and a tool call of one response share a row, Ctrl+C writes no row, the approve prompt is a cliclack select, bracketed paste on, no alternate screen. Not wired: MCP, skills, plugin hooks, usage/quota, account switching, model flag. pressly's migration tool also ships `goose`; identity_regex accepts only goose's bare version output. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
…by default review-524 MEDIUM-1. Goose has no permission-bypass flag because its default GOOSE_MODE=auto already approves every tool, and Navide's Guard does not cover Goose yet; the help table showed only "—" in the flag column, the same as CLIs that ask first. The Goose row now says so in en-US, zh-TW and ja-JP and how to be asked (GOOSE_MODE=approve or smart_approve). Disclosure only: Goose's launch command and behaviour are unchanged, no limit added. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
CI on #524 found five places the Goose vendor had not reached: - The packaged backend's hiddenimports did not list cli_vendors.goose (test_pyinstaller_spec). - goose.py branched on sys.platform; it now takes osplat.platform_id like droid, with a platform argument for tests (test_osplat). - The + menu roster scroller was capped at 360px, which carries fifteen CLIs: the sixteenth was cut off. Raised to 384px, and the flip threshold with it (ControlPane.addMenu). - TURN_START_SIGNAL did not classify goose. Its reader reports the user's prompt, so it gets the turn watch (submitTurnConfirm). - The version-drift check from main (#502) expects every vendor to carry an account-switch verified_version. Goose has no account-switch adapter, so it is listed as the one exception and its probe stays quiet. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Brings in #531 (Kimi Code). docs/en-US/cli-vendor-matrix.md conflicted in the version-on-record note: kept both the goose sentence and main's reworded (silence) bullet, and noted that the untested-version probe note never appears for goose (planned for 0.2.29). goose.py line ref updated. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
nt-nerdtechnic
marked this pull request as ready for review
October 21, 2026 01:20
nt-nerdtechnic
added a commit
that referenced
this pull request
Oct 21, 2026
Squash-merged from origin/pr-524. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Collaborator
Author
|
Squash-merged into main as b361afe. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Adds Goose (AAIF, formerly Block —
aaif-goose/goose) as the 16th CLI vendor at tier L4: install detection, launch, kickoff-marker session binding, a SQLite reader (turn end, reply text, tokens) andgoose session -r --session-id <id>resume with a db preflight, plus a screenawaitingInputpattern for the tool-approval prompt.Why
User decision 2026-10-20 23:27 (0.2.28). Research note n6 in plan
cli-10-19-0-2-28_411e93was source-only; this PR verifies each fact live before relying on it.Live verification (scratch only)
goose 1.55.0,
goose-aarch64-apple-darwin.tar.gzsha256153425d6dc3a49afce85e70009eff87f6020e3ed029bb56fae1b523f7f2d8107(matches the GitHub asset digest), binary sha256cabeb1c0…2491844c. Run withenv -i, a scratchHOME/XDG dirs/GOOSE_PATH_ROOT,GOOSE_DISABLE_KEYRING=1,GOOSE_TELEMETRY_OFF=1, against a loopback mock OpenAI endpoint started for the run (no account, no credential, no provider call, no global install; goose has no self-running updater). Findings that changed the design:~/.local/share/goose/sessions/sessions.db), not~/Library/Application Supportas the research note said (goose info).-n <name>is not unique: reusing a name creates a new session (20261020_2), so binding uses the kickoff marker, not names. Session ids areYYYYMMDD_Nin UTC.goose session -r --session-id <id>resumes; an unknown id exits withno such session exists→session_existsasks the db.messagesrow (verified by streaming them as separate chunks), and the loop ends on a response without a tool request → an agent-visible text-only assistant row is the turn end.usage_ledgerhas one row per model call;input_tokensalready includes cache (goose-provider-types token_usage.rs), matchingTokenUsage.◆ Goose would like to call the above tool, do you allow?(cliclack);ESC[?2004hat startup, noESC[?1049h.--versionprints a bare1.55.0; pressly's migration tool also installsgoose(goose version: v3.x), soidentity_regexaccepts only the bare shape.Not wired (left unsupported, stated in docs): MCP, skills, plugin hooks/Guard, usage/quota, account switching, model flag; Windows path (
%APPDATA%\Block\goose\data) and Windows install are source-only (wizard shows the docs link on win32).Test plan (red → green)
import agent_team_backend.cli_vendors.goose→ModuleNotFoundError, sobackend/tests/vendors/test_goose.pyand the[goose]contract cases cannot run.safe-pytest.sh <wt> -n 1 -k "test_goose or test_cli_vendors_registry or test_install_deps_snapshot or test_risk_declarations or test_cli_launch_argv or test_native_memory or test_cli_extensions or goose or test_catalog"→ 208 passedsafe-pytest.sh <wt> -n 1 -k goose -rA→ 24 passed, incl.test_vendor_reader[goose],test_vendor_resume[goose],test_vendor_launch[goose]pnpm vitest run src/renderer/src/platform/plugin-shell/agents tests/cli/vendorContracts.test.ts src/renderer/src/components/__tests__/CliAgentsHelp.test.ts src/renderer/src/platform/plugin-shell/lib/cliPermission.test.ts src/renderer/src/platform/plugin-shell/lib/resume-command.test.ts plugins/navide-plans src/renderer/src/lib/__tests__/quotaFailover.test.ts --maxWorkers=1→ 27 files, 584 passedpnpm typecheck→ exit 0;ruff checkon changed Python → clean.tests/fixtures/cli-regression/goose.json(provenancerecorded): the real schema from the 1.55.0 db and the recorded row shapes, with fixture text/ids/counts.Regression: existing plugins / features
The change is additive: one new vendor file per side plus registration lines. No shared module gained a goose branch; the only shared-harness change is
VendorDatasettingGOOSE_PATH_ROOT(read by goose only) so the Windows runner keeps the goose store inside the scratch home. Plans/Git/mini-IDE, messaging, channels and account switching code are untouched; the Plans retained-spec parity test (plugins/navide-plans, 74+82+… tests above) passes with the new row. Full suites are left to CI.Protection check
git diff 49721cd8e -- 'backend/agent_team_backend/credential_*' 'backend/agent_team_backend/quota_*' 'backend/agent_team_backend/usage_*' | wc -l→ 0. Goose declares noaccount_switch,fetch_usageor credential fields.git diff 49721cd8e | grep -E '^-\s*(def |async def |export (function|const)|class )'→ no match..gitleaks.toml/.gitleaksignore→ 0 leaks (canary detected).49721cd8e; files changed on main since (fix(claude): read the 2.1.304 resume dialogs as awaiting input #507, fix(registry): local Registry applies native backend package rules; prefix error names the prefix #510) do not overlap this PR (comm -12empty).Follow-ups on this branch
57c97b1c3closes five shared inventories the 16th vendor had missed (CI on989d40a6c):cli_vendors.goosein the PyInstaller hiddenimports;osplat.platform_idinstead ofsys.platformingoose.py; the + menu roster scroller raised from 360px (fifteen rows) to 384px withADD_MENU_MAX_H450 → 474;TURN_START_SIGNAL.goose = true; and the feat(cli): disclose a CLI newer than its verified version in the startup probe #502 version-drift check.--versionwithAccountSwitchSpec.verified_version. Goose has no account-switch adapter, so it has noverified_versionand the note never appears for goose panes in 0.2.28.test_spawn_probe_version_drift.pylists goose as the single exception (_NO_ACCOUNT_SWITCH) and still asserts the other 15 vendors carry one; the vendor matrix says the same. Giving goose the note needs a version field independent of account switching — planned for 0.2.29.820881be6merges mainfb1729cd6(incl. fix(kimi): read Kimi Code 0.39+/2.x state.json cwd and turn.ended; name the archived kimi-cli #531 Kimi); the only conflict was the version-on-record note indocs/en-US/cli-vendor-matrix.md, resolved by keeping both sides.🤖 Generated with Claude Code