From 66d8fcea99e49c5eba46f9415c6a930af97374f2 Mon Sep 17 00:00:00 2001 From: Peter Steinberger Date: Sat, 2 May 2026 05:29:00 +0100 Subject: [PATCH] fix: allow pinned release ci refs --- .github/workflows/openclaw-release-checks.yml | 4 ++-- test/scripts/package-acceptance-workflow.test.ts | 2 ++ 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/.github/workflows/openclaw-release-checks.yml b/.github/workflows/openclaw-release-checks.yml index baa35ec29a5..c21464fb02a 100644 --- a/.github/workflows/openclaw-release-checks.yml +++ b/.github/workflows/openclaw-release-checks.yml @@ -89,8 +89,8 @@ jobs: WORKFLOW_REF: ${{ github.ref }} run: | set -euo pipefail - if [[ "${WORKFLOW_REF}" != "refs/heads/main" ]] && [[ ! "${WORKFLOW_REF}" =~ ^refs/heads/release/[0-9]{4}\.[1-9][0-9]*\.[1-9][0-9]*$ ]]; then - echo "Release checks must be dispatched from main or release/YYYY.M.D so workflow logic and secrets stay controlled." >&2 + if [[ "${WORKFLOW_REF}" != "refs/heads/main" ]] && [[ ! "${WORKFLOW_REF}" =~ ^refs/heads/release/[0-9]{4}\.[1-9][0-9]*\.[1-9][0-9]*$ ]] && [[ ! "${WORKFLOW_REF}" =~ ^refs/heads/release-ci/[0-9a-f]{12}-[0-9]+$ ]]; then + echo "Release checks must be dispatched from main, release/YYYY.M.D, or a Full Release Validation release-ci/- ref so workflow logic and secrets stay controlled." >&2 exit 1 fi diff --git a/test/scripts/package-acceptance-workflow.test.ts b/test/scripts/package-acceptance-workflow.test.ts index 6386eb441ff..7f9b61f41d2 100644 --- a/test/scripts/package-acceptance-workflow.test.ts +++ b/test/scripts/package-acceptance-workflow.test.ts @@ -140,6 +140,7 @@ describe("package acceptance workflow", () => { it("requires full release child workflows to run at the resolved target SHA", () => { const workflow = readFileSync(FULL_RELEASE_VALIDATION_WORKFLOW, "utf8"); + const releaseChecksWorkflow = readFileSync(RELEASE_CHECKS_WORKFLOW, "utf8"); expect(workflow).toContain("TARGET_SHA: ${{ needs.resolve_target.outputs.sha }}"); expect(workflow).toContain("--json status,conclusion,url,attempt,headSha,jobs"); @@ -148,6 +149,7 @@ describe("package acceptance workflow", () => { "Dispatch Full Release Validation from a ref pinned to the target SHA", ); expect(workflow).toContain("| Child | Result | Minutes | Head SHA | Run |"); + expect(releaseChecksWorkflow).toContain("refs/heads/release-ci/[0-9a-f]{12}-[0-9]+"); }); it("keeps exhaustive update migration as a separate manual package gate", () => {