Auto-install Claude plugin on first front-door launch#311
Merged
clkao merged 2 commits intoJun 6, 2026
Conversation
…all opt-out) gateHost returns the contract verdict instead of a bool so runClaude can distinguish a missing plugin (recoverable by installing) from an incompatibility (auto-installing would just fail again). On NoPluginFound, runClaude auto-installs via the existing ops.Install path and proceeds to launch so the single command the user typed yields a working FO session; --no-install opts out, preserving the refuse-and-instruct behavior. Any mismatch / malformed range / host-CLI resolve error still fails fast. runCodex keeps its all-or-nothing gate (!= Compatible) — auto-install is Claude-only and Install rejects non-claude hosts. Settled the two recorded open decisions per the ideation recommendations: proceed-directly after install (no re-gate), and the phantom-installPath (resolved-but-missing manifest) NoPluginFound verdict auto-installs too. Migrated the no-plugin fail-fast tests to the default-auto-installs contract with --no-install as the fail-fast arm: the unresolvable/phantom-manifest cases now assert auto-install + launch by default and refuse under --no-install, and the gate-short-circuits-before-safehouse test exercises the refuse path. AC observables are the stub's installCmds / launchedArg / exit code, not string matches. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
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
spacedock claudetreat missing Claude plugin as recoverable: install plugin, then launch--no-installto preserve the old refuse-and-instruct pathValidation
go test ./internal/cli -count=1: 222 passedgo test ./...: 1123 passed in 16 packagesgo test ./... -race: 1123 passed in 16 packagesspacedock status --workflow-dir docs/dev --validate: VALIDTestClaudeFrontDoorFailFastOnMismatchRebase note
Rebased onto
origin/nextafter #310. A redundant comment-only status commit conflicted with #310 and was skipped; the rebased branch now contains only front-door changes ininternal/cli/frontdoor.go,internal/cli/frontdoor_test.go, andinternal/cli/safehouse_frontdoor_test.go.Workflow state:
docs/dev/.spacedock-state/spacedock-claude-auto-install-plugin/index.md.