installer-setup: hal0 setup --plan dry-run preview#1121
Merged
Conversation
Resolve the same Selections the real run would (via load_answers or build_auto_selections) and print a "will create" table — slots, extensions, ComfyUI defaults, model-store free space, port-in-use — writing NOTHING. This is the safe preview / CI-gate surface from the setup-answers spec §2/§8. Closes #1116. Co-Authored-By: Claude Opus 4.8 (1M context) <[email protected]>
ffe2bd3 to
822a6ac
Compare
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.
Closes #1116
Summary
Adds
hal0 setup --plan(alias--dry-run): resolves the answer file (or--autodefaults) into a concreteSelectionsthe SAME way the real runwould, then prints a "will create" table and writes NOTHING — no slot TOML,
no first-run sentinel, no pulls, no extension installs. This is the safe
preview / CI-gate surface from
handoffs/hal0-setup-answers-spec-2026-07-05.md§2 and §8.
src/hal0/cli/setup_plan.py(kept separate fromsetup_command.pytominimize merge conflicts with the sibling
--emit-answersPR installer-setup: hal0 setup --emit-answers round-trip #1117 touchingthe same callback): resolves selections via
load_answers(when--answersis given) orbuild_auto_selections(otherwise), then renders:shutil.disk_usage, warns below 10 GiB)when not explicit), and a port-in-use check (
socketbind probe)src/hal0/cli/setup_command.py: one new--plan/--dry-runtyper.Optionand one early-return branch — before any
run_install/apply_setupcall.non-zero, so
--planis a usable CI gate. An answer file'sstrict: trueflag additionally promotes the port-in-use check from a warning to an
error exit.
Test plan
uv run ruff format src tests— 635 files unchangeduv run ruff check src tests— all checks passeduv run ruff format --check src tests— 635 files already formatteduv run pytest tests/install/test_setup_plan.py tests/cli/ -q— 265 passed, 3 pre-existing hermes-venv failures (unrelated)uv run pytest tests/ -q --ignore=tests/e2e— 4620 passed, 14 known pre-existing failures (hermes venv/wrapper, comfyui phase4, proxmox host detection, container spec, config-url-proxy, models-preview, settings-store) — none touch files this PR changes--plan --autoprints the table and makes zero filesystem writes--plan --answers <good file>prints resolved slots--plan --answers <bad file>exits non-zero with the validation errorstrict: true)🤖 Generated with Claude Code