Repository navigation
Description
Epic: graph-2026-10-freeze Tier: mechanical Execution: sequant_run
Context
A stranger smoke test on 2026-10-09 followed the README's headless path on a repo that had never seen Sequant: npm install [email protected], npx sequant init --yes, npx sequant doctor, commit, then npx sequant run 21. The run passed end to end in 16 minutes. These are the first-run papercuts it hit, in the order a newcomer meets them. The --base PR bug from the same test is filed separately.
Findings
doctor(and every command) contradicts the README's install path. The README's "Headless / CI" path saysnpm install sequantthennpx sequant init. Every subsequent command then prints! Running sequant from local node_modules / For latest version: npx sequant@latest / To remove local: npm uninstall sequant(bin/cli.ts:172). A newcomer is told to undo the install the README just gave them.init's "Next steps" leave out the stepsequant runneeds. They list/spec 123,/exec 123,/qa 123and the constitution, but not "commit.claude/skills/" orsequant run.doctorthen warns that.claude/skills/{spec,exec,qa}are not committed and that phase worktrees won't see them.doctor's summary undercounts warnings. It printed two!lines (Skills Committed, and the Claude Code #43869 note), but the summary saidWarnings: 1andPassed: 19/20.- The progress timer labels the issue's elapsed time as the phase's. At 02:48:52, one minute into exec (started 02:47:45), the log read
still running: #21 exec (12m 11s): the time since the issue started, not since exec started. run --helpsays--no-rebaseskips the rebase "onto origin/main", but the rebase uses the--basebranch (rebaseBeforePR(…, baseBranch),batch-executor.ts:2586).
Observed but not filed as defects: init adds 66 files and about 23,000 lines to commit, 20,686 of them in .claude/skills (an adoption-cost question, related to #1209). On a trivial three-AC issue, spec took 9m43s of the 16-minute run on Opus.
Acceptance Criteria
- AC-1: The local-install warning no longer tells a user who followed the README to uninstall: either the README's headless path and the warning agree, or the warning is suppressed when the project's
package.jsondeclaressequantas a dependency. Evidence: a test on the warning predicate with a project whosepackage.jsonlistssequant, plus the README diff if the path changes. - AC-2:
init's "Next steps" include committing.claude/skills/(and the other generated files) before the firstsequant run, and namesequant run <issue>as a next step. Evidence: a test on the next-steps output. - AC-3:
doctor'sWarnings:count equals the number of!lines it printed, including the upstream-issue notes, or those notes are excluded from both. Evidence: a test on the summary with two warnings. - AC-4: The
still runningline shows time since the current phase started. Evidence: a test on the progress formatter with a phase that started after the issue. - AC-5:
run --helpdescribes--no-rebaseas skipping the rebase onto the base branch. Evidence: the help-text diff.
Decision for AC-1 (graph doc D-6)
Keep the README's headless install path. Suppress the local-install warning when the project's package.json declares sequant as a dependency; keep it for a stray install the project doesn't declare.
Prior fixes / producers
- The local-install warning dates from feat: Warn when running from local node_modules #87 (2026-01-17) and has not changed since; the README's headless path was written later. The other four are isolated papercuts, each with one producer. Deliberately local.
May touch
bin/cli.ts, src/commands/init.ts, src/commands/doctor.ts (summary, about line 1121), src/lib/cli-ui/run-renderer.ts (the still running line, about line 454), README.md, their tests.
Non-Goals
- Reducing what
initwrites (the about 23,000-line commit is investigation(run): load phase skills from the installed package via the SDK plugins option, so adopters stop committing ~20k lines of skills #1388's question). - Any edit under
plugin/,.claude/skills/ortemplates/skills/(plugin freeze, I-1 of the graph doc).
Activity
docs(#1390): graph-2026-10-freeze founding doc, issue graph and as-fi…
admarble commentedon Oct 10, 2026
Runner context for the phase agents (graph-2026-10-freeze, wave 1). This applies to the exec phase and the qa phase by name.
npm testin the worktree, in exec or in qa. Three phases run in parallel in this wave, and a full-suite run (10–13 min) under that load crosses the 30-minute phase wall and kills the phase. Run only the test files you touch or add (npx vitest run <file>…), in the foreground, with atimeout, after a WIP commit. The runner session runs the full suite on the PR branch after the PR opens.plugin/,.claude/skills/ortemplates/skills/. The runner checks this before any merge.CHANGELOG.md[Unreleased]: add your line; conflicts with sibling PRs are expected and the runner resolves them.failedTestfield starts with the test file path.admarble commentedon Oct 10, 2026
Complexity: Standard (5 ACs, 4 directories)
AC Quality Check
All five ACs are single-line, carry an
Evidence:clause, and are measurable. Notes:--no-rebaseoption description from the commander program and asserts it names the base branch and notorigin/main. That fails on current code.Scope Assessment
Non-Goals: present (init output size is #1388; no edits under
plugin/,.claude/skills/,templates/skills/).bin/,src/commands/,src/lib/,README.md)Verdict: ✅ SCOPE_OK
Acceptance Criteria
AC-1: local-install warning suppressed when
package.jsondeclaressequantVerification: Unit Test
Scenario: Given install at
<proj>/node_modules/sequantand<proj>/package.jsonlistingsequantin dependencies/devDependencies/optionalDependencies → When the warning predicate runs → Then no warning; withsequantundeclared → warning kept.Assumptions: The project root is derived from the install path (the directory that contains
node_modules/sequant), notprocess.cwd(), so a run from a subdirectory behaves the same. Unreadable or invalidpackage.jsonis treated as undeclared (warn).AC-2:
initnext steps name the commit step andsequant runVerification: Unit Test
Scenario: Given init completes → When next-steps content is built → Then it includes a commit step naming
.claude/skills/and the other generated files, beforesequant run <issue>.Assumptions: Use
resolveCliInvocation()-stylenpx sequant run <issue>wording consistent with the README.AC-3:
Warnings:equals printed!linesVerification: Unit Test
Scenario: Given one failing-to-warn check plus the upstream #43869 notice → When the summary is built → Then
Warnings: 2.Assumptions:
--quietsuppresses the notice, so it must not be counted then.AC-4:
still runningshows time since the current phase startedVerification: Unit Test
Scenario: Given issue started at T0, exec started at T0+11m, now = T0+12m → When heartbeat ticks → Then line reads
#21 exec (1m 0s).AC-5:
--no-rebasehelp names the base branchVerification: Unit Test (reads option description)
Scenario: Given the
runcommand registered → When--no-rebasedescription is read → Then it says "onto the base branch" (mentions--base), notorigin/main.Implementation Plan
Phase 1: Code (4 independent edits)
src/lib/version-check.ts: addisDeclaredDependency(installPath = __dirname)(walk up to the dir abovenode_modules/sequant, readpackage.json, check the three dependency maps). Inbin/cli.ts:166the branch becomesisLocalNodeModulesInstall() && !isDeclaredDependency(). Keep the home-stray branch as is. Extract the predicate asshouldWarnLocalInstall(installPath)so the test targets it directly.src/commands/init.ts:1310: extractbuildNextSteps()(exported); add "Commit generated files (git add .claude/ .sequant/ … && git commit)" and "npx sequant run <issue>" steps.src/commands/doctor.ts: makeemitUpstreamWarningreturnboolean(true when it printed); add that towarnCountandtotalChecksbefore the summary. Extract summary-building into a purebuildDoctorSummary({pass,warn,fail})for the test.src/lib/cli-ui/run-renderer.ts:439: use the running phase'sstartedAt(s.phases.find(p => p.name === s.currentPhase)), falling back tos.startedAt.bin/cli.ts:399: description → "Skip pre-PR rebase onto the base branch (--base, default main) …". Check whetherdocs/or README repeat the old wording (whole-repo grep forrebase onto origin/main), update every location except frozen dirs.Phase 2: Tests and housekeeping
version-check.test.ts, init, doctor, run-renderer, and a CLI-help test). Run only those files.CHANGELOG.md[Unreleased]line. README unchanged under D-6 (headless path stays).Design Review
version-check.tsbesideisLocalNodeModulesInstall; the others where the text is produced.package.json. Rejected: changing the README tonpx sequant@latest(decided against in D-6); rejected: deleting the warning (a stray undeclared install is the case it exists for).git log -Sfound no prior fix issues in the sites, so under the ≥2 rule this is not a stop; deliberately local, as the issue records.process.cwd()/package.json?" The install root is exact and survives subdirectory runs. "Why doesPassed: x/ychange?"ynow includes the notice, so the counts stay consistent with the printed lines.bin/cli.ts);isLocalNodeModulesInstallhas other consumers (version-check.ts:161,410,435,466) that must stay unchanged.emitUpstreamWarning: one call site (doctor.ts) plus its tests.still running: one producer. Next steps: one producer. Help text: one producer inbin/cli.ts, possibly mirrored in docs.Feature Quality Planning
All standard checks pass. Notable items:
--quiet(notice suppressed, not counted).Passed: N/Nor the old next steps will need updating; grep before editing.⏸) is untouched; keep it so.Open Questions
Passed: 19/20, Warnings: 2reads oddly.Recommended Workflow
Phases: testgen → exec → qa
Quality Loop: disabled
Reasoning: All five ACs declare unit-test evidence, so testgen stubs help; small, isolated bug fixes. No UI, no security surface. Per the runner comment: no full
npm testin exec or qa.Label Review
Current: bug, graph-2026-10-freeze
Recommended: add
plannedQuality Loop: Won't auto-enable (SCOPE_OK).
admarble commentedon Oct 10, 2026
Test Stubs Generated
--quiet)Unit Test Stubs
src/lib/version-check.declared-dependency-1387.test.tssrc/commands/init.next-steps-1387.test.tssrc/commands/doctor.summary-count-1387.test.tssrc/lib/cli-ui/run-renderer.phase-elapsed-1387.test.tssrc/commands/run-help-no-rebase-1387.test.tsEach stub is
throw new Error(...)until implemented. They depend on the seams named in /spec (shouldWarnLocalInstall,buildNextSteps,buildDoctorSummary, per-phasestartedAt, registered--no-rebaseoption).Next steps:
/exec 1387— implement the fixes and fill in the stubsnpx vitest run <file>), not the full suiteGenerated with Claude Code
admarble commentedon Oct 10, 2026
QA Verdict: AC_NOT_MET
AC coverage: 4/5 met
Gaps:
fix(#1387): init's printed git add names only paths init wrote, never…
fix(#1387): a pnpm install the project declares no longer gets the lo…
chore(#1387): prettier
admarble commentedon Oct 10, 2026
QA Verdict: AC_MET_BUT_NOT_A_PLUS
AC coverage: 5/5 met
Gaps:
fix(#1387): doctor's outdated-version remediation no longer prints a …
admarble commentedon Oct 10, 2026
Runner decision on QA round 2's
documentfinding (a hoisted workspace install declared only in a workspace package'spackage.jsonstill gets the local-install warning): deliberately not handled in #1393.isDeclaredDependencyreads thepackage.jsonnext to the install (above the pnpm store for pnpm). Walking up to find workspace members is beyond a papercut fix, and the cost is a warning that shouldn't print, not wrong behaviour. Reopen as its own issue if a workspace user reports it.fix(#1387): first-run papercuts — local-install warning, init commit …