fix(ship): exclude current PR from queue-awareness (self-reference bug)

Version gate flagged PR #1168 as stale because the util counted the PR
itself as a queued claim. The exclude filter removes that self-reference.

New --exclude-pr <N> flag on bin/gstack-next-version. CI workflows pass
github.event.pull_request.number / CI_MERGE_REQUEST_IID. Local /ship
auto-detects via gh pr view when the flag isn't passed, with a warning
recording the auto-exclusion so it's observable.

Caught during the first live ship through the v1.8.0.0 gate — the kind
of dogfood the whole release is designed for.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
Garry Tan
2026-04-23 11:28:02 -07:00
parent bd39b6995f
commit 416a56a5c8
3 changed files with 35 additions and 9 deletions

View File

@@ -35,6 +35,7 @@ version-gate:
--bump "$LEVEL" \
--current-version "$BASE_VERSION" \
--workspace-root null \
--exclude-pr "$CI_MERGE_REQUEST_IID" \
> next.json
RC=$?
if [ "$RC" != "0" ] || [ ! -s next.json ]; then