Skip to content

feat(install-tend): gather install preferences in one kickoff round - #1010

Merged
max-sixty merged 3 commits into
mainfrom
onboarding
Aug 19, 2026
Merged

max-sixty merged 3 commits into
mainfrom
onboarding

Conversation

@max-sixty

@max-sixty max-sixty commented Aug 19, 2026 •

Copy link
Copy Markdown
Owner

An all-defaults install now costs one dialog. The Kickoff gathers every preference in a single AskUserQuestion round, and the rest of the install stops only where a step genuinely needs the user — bot-account signup, OAuth approval, the device-code approval, the push.

Installing on a repo previously took eight questions across three rounds: harness, bot name, "Ready to start?", workflow overrides, overlay contents, badge yes/no, bio stance, and the harness auth mode — each at its own step, so an agent following the skill literally interrupts even more often than one that batches them. Every one of those had a recommended option that was taken.

The round asks three questions: Harness (Claude/OAuth, Claude/API key, or Codex — folding in what step 7a used to ask separately), Bot name (availability-checked candidates, recommended first), and Customize, a multiselect of the four areas that have safe defaults, each option naming its default. Submitting it with nothing selected accepts every default. Answering the round is the go-ahead, so the separate "Ready to start?" confirmation is gone; a request that already specifies everything asks nothing at all.

Steps 1, 4, 5 and 10 apply their defaults silently unless their area was picked, and 7a now routes the OAuth mint path (bundled wrapper vs. paste-it-back) by checking the environment rather than asking. The badge changes from "offer to add" to added-by-default with opt-out — the one behavior change here rather than a re-arrangement of who asks what.

Supporting fixes the restructure forced, or that review surfaced
  • Kickoff branches on install completeness rather than config presence. .config/tend.yaml is written in step 1 of 11, so an install interrupted anywhere after that used to resume down the "this is a change" path, which asks nothing; it now resumes through the round with the questions the config already answers dropped.
  • 7a asks the auth mode lazily when no round settled it. The config records the harness, never which Claude credential, so a change flow or a resumed install reaches the mint step without an answer.
  • Both nested customize multiselects listed five options against AskUserQuestion's hard cap of four, so the user who opted into customizing was the one who hit a tool error. Merged to four each.
  • REPO derivation resolves a fork clone to its root source using the generator's own recipe, and confirms with the user when that changes the name or comes back null — a maintained hard fork keeps its own name.
  • Step 6 asks which email the bot account should use, step 11 states that merging is the user's call, and step 3 loses a stale OWNER/REPO placeholder and a reference to a checkbox that doesn't exist at that point.

Reviewed by an adversarial pass over the restructured flow (which verified the AskUserQuestion limits against the installed binary rather than from memory) and a blind walkthrough that traced an all-defaults install and a resume-after-interrupt. A design challenge weighed three alternative shapes — zero questions with the name defaulted too, a config-file-first flow, and deferring every ask to the end — and none dominates. The round is the cheapest checkpoint that still lands before the first irreversible action on the normal path; a request that specifies everything skips it by design, and reaches step 3's ruleset POST without a further prompt.

This was written by Claude Code on behalf of max-sixty

max-sixty and others added 2 commits August 18, 2026 17:33
An all-defaults install now answers a single AskUserQuestion dialog:
harness+auth mode, bot name (availability-checked candidates), and a
customize multiselect where submitting with nothing selected accepts
every default. Steps 1/4/5/10 apply their defaults silently unless the
area was picked; 7a routes the OAuth mint path (CLI vs manual) by
environment instead of asking; the separate "Ready to start?"
confirmation is gone — answering the round is the go-ahead.

Supporting changes the restructure forced or review surfaced:

- Kickoff branches on install completeness rather than config presence,
  so an interrupted install resumes through the round, dropping
  questions the config already answers; 7a asks the auth mode lazily
  when no round settled it (the config never records it).
- REPO derivation resolves fork clones to their root source (the
  generator's own recipe), confirming with the user only when that
  changes the name or returns null.
- Both nested customize multiselects merged to 4 options —
  AskUserQuestion's hard cap, which the old 5-option lists exceeded.
- Step 6 asks which email the bot account should use; step 11 notes
  merging is the user's call; step 3 placeholder/wording cleanup.

Co-Authored-By: Claude Fable 5 <[email protected]>
# Conflicts:
#	plugins/install-tend/skills/install-tend/SKILL.md

@tend-agent tend-agent left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Two things in the Kickoff, both inline.

The completeness gate cites uvx tend@latest check as reporting workflows-committed, and it doesn't — run_all_checks in generator/src/tend/checks.py runs branch-protection, bot-permission, environment, environment-deployments, credential-environments, secrets, harness-auth and repo-secret-allowlist, and nothing asserts tend-*.yaml exists. The one workflow-reading check, check_environment_deployments, returns True when the sweep finds no offenders — including when there are no tend workflows at all. That matters for exactly the case this branch is trying to catch: step 11 commits without pushing, so an install that stopped at "committed, awaiting the user's go-ahead" has every secret set, the bot a collaborator, the rulesets in place, and no tend-*.yaml on the default branch. tend check is green, the gate reads "finished install", and the resume routes down the change path — which lays out only the steps the task touches and never regenerates.

Separately, AskUserQuestion's options array is .min(2).max(4), not just capped at 4. The PR fixed the overflow side on both nested multiselects; question 2 can still underflow, since only the all-taken case is handled.

One observation rather than a finding: the PR body's design note says this is "the cheapest checkpoint that still lands before the first irreversible action", but the fully-specified-request path asks nothing, and the first thing that mutates the repo is step 3's ruleset POST. On a repo with no release secrets to migrate, nothing between "install tend on this repo as foo-bot with Codex" and a created ruleset involves the user. That may well be the intent — the user did ask for an install — but it's a different property than the one the note claims.

Checked and fine
  • The REPO recipe matches detect_canonical_owner in checks.py (.fork → .source, root not parent), and jq indexing a missing .source yields null rather than erroring, so the stated null branch is reachable as described.
  • Option counts elsewhere: Kickoff q1 is 3, q3 is 4 (3 with no README), step 1's override list is 4, step 4's overlay list is 4. All inside 2–4.
  • Dropping q1 for a config-present resume is consistent with 7a's lazy auth-mode ask, since the config records the harness but not the credential.
  • No dangling references to the removed "Ready to start?" step, and the README line matches step 5's new default-on behavior.

… gate

`tend check` verifies secrets, bot access and protection; nothing in
run_all_checks asserts `tend-*.yaml` exists, and the one workflow-reading
check passes vacuously when the sweep finds no offenders — including on a
repo with no tend workflows at all. Step 11 commits without pushing, so an
install stopped there has every secret set and the bot a collaborator with
no workflows on the default branch: the gate read that as finished and
routed the resume down the change path, which never regenerates.

The bot-name question also needed the other end of AskUserQuestion's
options bound: the array is min 2, so two of three candidates being taken
ships one option and the call is rejected.

Co-Authored-By: Claude Fable 5 <[email protected]>
@max-sixty
max-sixty merged commit 9ee63df into main Aug 19, 2026
9 checks passed
@max-sixty
max-sixty deleted the onboarding branch August 19, 2026 02:12
max-sixty added a commit that referenced this pull request Aug 19, 2026
…ipe runnable (#1012)

Follow-ups #4/#5/#6 from #1010, none of which had been tested.

- **Kickoff question 3 becomes an accept-defaults/customize gate.** The
all-defaults path answers one dialog of three single-selects, so the
empty-multiselect submission — and Claude Code's "You have not answered
all questions" banner it trips — can't occur. The four-area multiselect
fires only on Customize…, where selection can only mean "change this
area" (the old labels read as include/exclude toggles). Both surfaces
list only areas still open: a request-settled area follows the request
at its step, an already-applied area stays put, and the default bio is
quoted rather than called "recommended" sight-unseen.
- **Step 7a's CLI mint path names its mechanism** instead of a bare "run
it in the background" over a blocking `TOKEN=$(...)` snippet: launch the
pipeline via the Bash tool's `run_in_background` (a foreground call
traps the authorize URL in its pending result and times out before the
user has anything to click), hand over the URL from the task output, and
read the task's exit status as the sole success signal. Validated
against a live `claude setup-token` run: the URL lands in the task
output within seconds, and a failed run exits non-zero having stored
nothing.
- **The overlay the skill writes gains frontmatter.** The `running-tend`
overlay is loaded by skill discovery, which needs `name`/`description`
frontmatter the placeholder never had — every adopter shipped an overlay
the CI sessions never loaded. The requirement now covers the
customized-overlay path too, and an existing overlay without the
frontmatter (PRQL and numbagg ship exactly that shape) is repaired in
place rather than skipped as already done.
- **Follow-through on #1011**, which rewrote the same 7a section and
merged mid-branch: its start-when-at-browser gate moved ahead of the
launch instruction (where a top-to-bottom reader needs it), and four
inherited gaps closed — a completion signal for the user-runs-`gh secret
set` paths (the step's pre-check printing SET), `gh` logged in as the
maintainer on the Manual machine, step 1's registry Manual route keeping
the token out of the chat transcript like 7a now does (with the
repo-level delete gated on the secret appearing in the environment), and
a duplicated URL in 7b.

Reviewed by an adversarial pass and a context-blind walkthrough that
traced five scenarios (all-defaults, customize, no-README, resume, the
OAuth mint executed literally); all findings fixed and re-verified,
including a post-merge pass over the composed 7a.

**Testing**: the wrapper's unit tests pass; the SKILL.md changes are
prose, covered by the blind walkthrough rather than code tests.

> _This was written by Claude Code on behalf of max-sixty_

---------

Co-authored-by: Claude Opus 5 (1M context) <[email protected]>
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.

2 participants