Skip to content

Commit 9b50b12

Browse files
etrclaude
andcommitted
CI: fix parallel-install gate ref check (--end-of-options, not --)
The TASK-044 v1+v2 parallel-install gate always false-SKIPped with "ref 'origin/master' not in this repository" even though the CI step successfully fetches origin/master. Cause: the Phase-2 ref probe used `git rev-parse --verify -- "$MASTER_REF"`. The `--` makes rev-parse treat the following argument as a PATHSPEC, not a revision, so it never resolved the ref (verified locally: `rev-parse --verify -- origin/master` fails, `rev-parse --verify origin/master` succeeds). Since skip is not authorized in CI, the gate failed the gcc-14 dynamic lane on every run. Use `--end-of-options`, which ends option parsing (preserving the guard against an option-like MASTER_REF) while still treating the argument as a revision. Line 176's `worktree add` takes the ref as a trailing positional and is unaffected. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01NpysYDDJac63yz2mZKKiDf
1 parent 19608ee commit 9b50b12

1 file changed

Lines changed: 5 additions & 1 deletion

File tree

scripts/check-parallel-install.sh

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -160,7 +160,11 @@ pass "v2 install succeeded into $SHARED_STAGE"
160160
# ---- Phase 2: materialise v1 source via git worktree --------------------------
161161
echo "Phase 2: building $MASTER_REF in a temporary git worktree"
162162

163-
if ! git -C "$REPO_ROOT" rev-parse --verify -- "$MASTER_REF" >/dev/null 2>&1; then
163+
# `--end-of-options` (not `--`) guards against an option-like MASTER_REF while
164+
# still treating it as a revision: `rev-parse --verify -- <ref>` interprets the
165+
# arg after `--` as a PATHSPEC, so it never resolves the ref and the gate always
166+
# false-SKIPped ("ref not in this repository") even when origin/master was fetched.
167+
if ! git -C "$REPO_ROOT" rev-parse --verify --end-of-options "$MASTER_REF" >/dev/null 2>&1; then
164168
skip_or_fail "ref '$MASTER_REF' not in this repository — cannot do automated v1 build"
165169
fi
166170

0 commit comments

Comments
 (0)