Summary
git-tree-reset.sh --dry-run does not validate that the upstream (@{u}) actually resolves, so a clean-looking dry-run (Blocked: none) does not predict that --apply will fail. Dry-run/apply parity is broken for the deleted-upstream case.
Component
plugins/repo-hygiene/skills/clean/scripts/git-tree-reset.sh.
Root cause
The dry-run branch (lines ~154–165) prints PlannedReset: git reset --hard <UPSTREAM> and previews git clean -fdxn, but never verifies the upstream ref exists. When UPSTREAM is the literal @{u} (see companion unresolved-upstream issue), dry-run still reports Blocked: none and a nonzero wouldRemove count, implying the apply will proceed cleanly.
Evidence (this session)
Dry-run sweep across 16 repos reported blocked=none for the 6 feature-branch repos whose upstream was gone. The subsequent --apply then failed on every one of those 6 with fatal: ambiguous argument '@{u}'. The dry-run gave zero warning.
Impact
Dry-run is the safety gate the skill's own workflow mandates before --apply. If dry-run cannot surface a condition that will fail (or partially execute destructively) at apply time, the gate provides false assurance.
Expected
Dry-run performs the same upstream-resolution validation as apply and reports the blocked/unresolved state, so dry-run success ⇒ apply will not fail on upstream resolution.
Acceptance criteria
Summary
git-tree-reset.sh --dry-rundoes not validate that the upstream (@{u}) actually resolves, so a clean-looking dry-run (Blocked: none) does not predict that--applywill fail. Dry-run/apply parity is broken for the deleted-upstream case.Component
plugins/repo-hygiene/skills/clean/scripts/git-tree-reset.sh.Root cause
The dry-run branch (lines ~154–165) prints
PlannedReset: git reset --hard <UPSTREAM>and previewsgit clean -fdxn, but never verifies the upstream ref exists. WhenUPSTREAMis the literal@{u}(see companion unresolved-upstream issue), dry-run still reportsBlocked: noneand a nonzerowouldRemovecount, implying the apply will proceed cleanly.Evidence (this session)
Dry-run sweep across 16 repos reported
blocked=nonefor the 6 feature-branch repos whose upstream was gone. The subsequent--applythen failed on every one of those 6 withfatal: ambiguous argument '@{u}'. The dry-run gave zero warning.Impact
Dry-run is the safety gate the skill's own workflow mandates before
--apply. If dry-run cannot surface a condition that will fail (or partially execute destructively) at apply time, the gate provides false assurance.Expected
Dry-run performs the same upstream-resolution validation as apply and reports the blocked/unresolved state, so dry-run success ⇒ apply will not fail on upstream resolution.
Acceptance criteria
Blocked:reason apply would (e.g.upstream-unresolved).