Repository navigation
fix(#709): non-interactive update path — add --yes, replace ExitPromptError crash - #715
Merged
admarble merged 3 commits intoJun 4, 2026
Conversation
…tError crash `sequant update` was interactive-only and crashed with a raw ExitPromptError stack trace when run without a TTY. Add `-y, --yes` to apply updates without prompting, and guard both prompt sites (first-run dev-URL setup and apply-confirm): when a prompt is needed but stdin is not a terminal and --yes was not passed, print an actionable message naming --yes and exit non-zero. --yes (auto-answer) stays distinct from --force (overwrite in-place customizations). Docs updated in cheat-sheet and troubleshooting. Entire-Checkpoint: d53130c95a6b
This was referenced Jun 4, 2026
…-run preview Two follow-up gaps from QA review of the non-interactive update path: - CI with an allocated pseudo-TTY would still prompt and hang, because the guard keyed on `isStdinTTY()` alone. Route both prompt sites through a new `isNonInteractive()` (= `!isStdinTTY() || isCI()`) so unattended CI jobs refuse cleanly. The refusal message now names the actual reason via `getNonInteractiveReason()`. - `update --dry-run` on a first-run (no-config) project refused with exit 1 and, on the apply path, previously persisted config as a side effect. Add a dry-run branch to first-run setup that previews with default tokens without prompting, and skip `saveConfig` in dry-run so a preview leaves the project untouched in any shell. Adds integration tests for both (CI-refuses-with-TTY, dry-run-first-run-no-write) and updates CHANGELOG + troubleshooting docs.
…e-no-non-interactive-path-crashes-without # Conflicts: # CHANGELOG.md
admarble
deleted the
feature/709-fix-update-no-non-interactive-path-crashes-without
branch
June 4, 2026 04:18
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
-y, --yestosequant updateto apply updates without prompting (CI / non-interactive shells).--yesprints an actionable message naming--yesand exits non-zero, instead of crashing with a rawExitPromptErrorstack trace.--yes(auto-answer) stays distinct from--force(overwrite in-place customizations).--yesand the automation path (paired with the fix(update/sync): sync reports 'up to date' on content drift; update overwrites in-place customizations (constitution) #708syncfix).Pre-PR AC Verification
update --yes/-yapplies updates without promptingbin/cli.tsflag;update.ts:184skips confirm; testAC-1+ E2E:echo "" | update --yes→ "Updated 5 files", exit 0--yes→ actionable message naming--yes, clean non-zero exit, noExitPromptErrorupdate.tsrefuseNonInteractive()on both prompt sites; testsAC-2x2; E2E: pipedupdate→ message + exit 1, no stack trace--help, cheat-sheet, troubleshooting document--yes+ automation guidance--helpshows-y, --yes;docs/reference/cheat-sheet.md;docs/troubleshooting.mdTest plan
npm run build— passesnpm run lint— passes (0 warnings)npx vitest run src/commands/update.integration.test.ts— 5/5 pass (3 new for AC-1/AC-2)--yes→ clean message + exit 1 (noExitPromptError); with--yes→ applies updates, exit 0Notes
Touches
bin/cli.ts— coordinate with #713 (also editsbin/cli.ts); rebase whichever merges second. The change is a single additive.option()on theupdatecommand, so conflicts should be trivial.Closes #709
🤖 Generated with Claude Code