You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
fix: /ship Steps 7-8 not idempotent — re-run after partial failure corrupts VERSION and CHANGELOG #649
/ship executes a multi-step sequence: version bump → changelog → commit → push → PR create. If Step 7 (git push) succeeds but Step 8 (gh pr create) fails (GitHub API outage, auth token expiry, rate limiting), re-running /ship corrupts state:
VERSION gets double-bumped (e.g., 0.13.5 → 0.13.6 on first run, then 0.13.6 → 0.13.7 on re-run)
CHANGELOG gets duplicate entries (same changes listed under two versions)
No way to safely resume from where it left off
The dangerous window is narrow (one step) but the blast radius is real — manual cleanup is required.
Why this matters
/land-and-deploy already handles partial failure well (Step 6 offers revert, Step 8 has full revert procedure with branch protection awareness). /ship doesn't apply the same rigor despite being the more frequently used skill.
Suggested fix
Make the critical section idempotent rather than building a rollback framework:
Before push: check if branch is already pushed (git rev-parse @{u} or git ls-remote)
Before PR create: check if a PR already exists for the branch (gh pr list --head <branch>)
Before version bump: check if VERSION was already bumped in a prior run (compare against base branch)
This is ~10 lines of shell, not a new subsystem.
Reproduction
# 1. Run /ship on a feature branch# 2. Simulate gh failure: revoke token or disconnect network after push# 3. Re-run /ship# 4. Observe: VERSION bumped again, CHANGELOG has duplicate section
Context
/land-and-deploy already handles this pattern (Steps 6, 7, 8 all have failure recovery)
@16francej Please close this issue as resolved. Ship reruns after partial failures are now handled safely by #693 and the newer version-state checks, so rerunning no longer corrupts VERSION or CHANGELOG.
Resolved on current main. The original idempotency work landed in #693; the current workflow retains version-state classification (ALREADY_BUMPED keeps the existing version), remote-head equality checks, and existing-PR/MR updates rather than duplicate creation. The changelog workflow replaces overlapping branch entries with one unified entry. Merged #2970 further clarifies recovery without weakening verification. Closing as completed; the superseded alternate PR #684 is also closed.
Activity
fix: add idempotency guards to /ship Steps 4, 7, 8 (#649)
test: add name patching + ship idempotency tests (#620, #649)
fix: ship idempotency + skill prefix name patching (v0.14.3.0) (#693)
fix: ship idempotency + skill prefix name patching (v0.14.3.0) (garry…
time-attack commentedon Jul 15, 2026
@16francej Please close this issue as resolved. Ship reruns after partial failures are now handled safely by #693 and the newer version-state checks, so rerunning no longer corrupts VERSION or CHANGELOG.
capy-ai commentedon Sep 24, 2026
Resolved on current main. The original idempotency work landed in #693; the current workflow retains version-state classification (ALREADY_BUMPED keeps the existing version), remote-head equality checks, and existing-PR/MR updates rather than duplicate creation. The changelog workflow replaces overlapping branch entries with one unified entry. Merged #2970 further clarifies recovery without weakening verification. Closing as completed; the superseded alternate PR #684 is also closed.
fix: ship idempotency + skill prefix name patching (v0.14.3.0) (garry…