Skip to content

fix(doctor/run): doctor and run --dry-run report success when nothing would work #1257

Closed

Description

@admarble

Problem

Two commands report success in states where nothing would work, which is the worst case for a first-time user deciding whether setup worked. Found by a blind new-user walkthrough; reproduced on 2.18.0.

  1. sequant doctor outside a git repo prints Passed: 16/17 ... Sequant should work correctly. It also reports All 18 checks passed! Your Sequant installation is healthy. in a git repo that has no GitHub remote and uncommitted .claude/skills/, both of which block sequant run.
  2. sequant run 1 --dry-run outside a git repo, for an issue that does not exist, prints #1 ✔ passed spec → exec → qa and 1 passed · 0 failed.

Acceptance Criteria

  • AC-1: sequant doctor fails (non-zero exit, not "should work correctly") when the cwd is not inside a git repository. Evidence: test covering a non-git temp dir.
  • AC-2: sequant doctor warns when the repo has no GitHub remote, naming the fix (gh repo create / git remote add). Evidence: test with a remote-less temp repo.
  • AC-3: sequant doctor warns when .claude/skills/ exists but is untracked by git, saying phase worktrees will not see it. Evidence: test.
  • AC-4: sequant run --dry-run does not report ✔ passed; dry-run rows show a distinct "planned" / "would run" state and the summary does not count them as passed. Evidence: test asserting the rendered row and summary.
  • AC-5: sequant run --dry-run N reports an error for an issue number that does not exist on the remote when gh is available. Evidence: test with a stubbed gh returning not-found.

Activity

  1. added
    bug
    cli
    on Oct 1, 2026
  2. admarble commented on Oct 1, 2026

    @admarble
    ContributorAuthor

    Execution Verification (part 1: AC-1, AC-4)

    Commands: fix-branch build of sequant doctor and sequant run 1 --dry-run, in a non-git scratch directory; doctor again two levels below a repo root; the dry run again under a real pty (Ink TUI) and piped (plain renderer)
    Result: Verified by human review

    Execution Output (click to expand)

    doctor outside a git repo (exit 1, was exit 0 with "Sequant should work correctly"):

      ✖ Git Repository: Not inside a git repository. Run sequant from your project's git checkout (or `git init` first)
    1 check failed
    Passed: 16/17
    Failed: 1
    

    doctor in <repo>/deep/dir:

      ✔ Git Repository: Git repository detected
    

    run 1 --dry-run, terminal (TUI):

    │ phases ○ spec   ▸   ○ exec   ▸   ○ qa │
    ○ #1 Issue #1 (planned)
    SUMMARY · 1 issue · 0s · 1 planned · nothing executed
      ○ planned  #1  spec → exec → qa
      1 planned · nothing executed
    

    run 1 --dry-run, piped (exit 0; was ✔ #1 spec 0s … #1 ✔ passed … 1 passed · 0 failed):

    [01:24:24] ○ #1 spec planned
    [01:24:24] ○ #1 exec planned
    [01:24:24] ○ #1 qa planned
    SUMMARY · 1 issue · 0s · 1 planned · nothing executed
      │ #1       │ ○ planned  │ spec → exec → qa │ 0s │
      1 planned · nothing executed
    

    Human Confirmation:

    Yes, looks correct (and asked for the per-phase progress lines to be fixed in the same change, which they are)

    AC-2, AC-3 and AC-5 (missing remote, untracked skills, nonexistent issue) are not in this change.


    Verified by /verify command

  3. added a commit that references this issue on Oct 1, 2026
  4. admarble commented on Oct 1, 2026

    @admarble
    ContributorAuthor

    Execution Verification (part 2: AC-2, AC-3, AC-5)

    Commands: fix-branch build of sequant doctor in a fresh git repo with no remote and .claude/skills/{spec,exec,qa} copied in but uncommitted, then again after adding a GitHub remote and committing; sequant run 999 --dry-run and sequant run 2 --dry-run in a clone of sequant-io/sequant-example (#999 does not exist, #2 does)
    Result: Verified by human review

    Execution Output (click to expand)

    No remote, skills uncommitted:

      ✔ Git Repository: Git repository detected
      ! GitHub Remote: No git remote. `sequant run` needs a GitHub remote to read issues and open PRs: run `gh repo create` or `git remote add origin <url>`
      ! Skills Committed: Not committed to git: .claude/skills/spec, .claude/skills/exec, .claude/skills/qa. Phase worktrees are checked out from git and won't see them. Commit .claude/skills/ before your first `sequant run`
    

    After git remote add origin https://github.com/... and committing the skills:

      ✔ GitHub Remote: GitHub remote configured
      ✔ Skills Committed: Core skills are committed
    

    run 999 --dry-run (exit 1):

      ✖ Issue #999 was not found in this repository, so a real run would fail. Check the number, or run from the repo the issue belongs to.
    

    run 2 --dry-run (exit 0):

    SUMMARY · 1 issue · 1s · 1 planned · nothing executed
      1 planned · nothing executed
    

    Human Confirmation:

    It looks right. Move forward.


    Verified by /verify command

  5. added a commit that references this issue on Oct 1, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugcli

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions