diff --git a/.github/workflows/lazurio-cli-archives.yml b/.github/workflows/lazurio-cli-archives.yml index 145b4470090fe..8036304fa8380 100644 --- a/.github/workflows/lazurio-cli-archives.yml +++ b/.github/workflows/lazurio-cli-archives.yml @@ -22,6 +22,11 @@ on: required: false default: ${{ github.repository }} type: string + darwin_runner: + description: Runner for the darwin-arm64 build; only the release passes its own Mac, pull requests keep GitHub's + required: false + default: macos-15 + type: string permissions: contents: read @@ -44,7 +49,7 @@ jobs: transcribe_native: linux-x64-cpu-vulkan transcribe_library: libtranscribe.so - key: darwin-arm64 - runner: macos-15 + runner: ${{ inputs.darwin_runner }} platform: mac arch: arm64 rust_target: aarch64-apple-darwin @@ -188,6 +193,10 @@ jobs: launcher: name: Launcher install linux-x64 needs: build + # Needs only the linux-x64 archive: a darwin job without a runner (#218) must not skip it, and + # a failed linux-x64 build still fails this job when its artifact is missing. Part of the #220 + # exception by the coordinating agent under the release owner's night mandate (#185). + if: ${{ !cancelled() }} runs-on: ubuntu-24.04 timeout-minutes: 20 env: diff --git a/.github/workflows/lazurio-release.yml b/.github/workflows/lazurio-release.yml index 7d1d713e88de6..19fa2858559cb 100644 --- a/.github/workflows/lazurio-release.yml +++ b/.github/workflows/lazurio-release.yml @@ -128,6 +128,10 @@ jobs: with: version: ${{ inputs.version }} source_sha: ${{ inputs.source_sha }} + # Temporary exception (Lazurio/t3code#218, #185, #220): hosted macos-15 gets no runner here, so the + # release builds darwin-arm64 on its own ephemeral Mac and the darwin PR check is not required. + # Both are undone when a whole release or preview run gets a hosted macOS runner and passes. + darwin_runner: lazurio-release-macos publish: name: Publish release and image diff --git a/scripts/lazurio-release-contract.test.mjs b/scripts/lazurio-release-contract.test.mjs index 65acdaae1a149..4dce8c8c88c99 100644 --- a/scripts/lazurio-release-contract.test.mjs +++ b/scripts/lazurio-release-contract.test.mjs @@ -293,7 +293,19 @@ NodeTest.test("archives are built with upstream's own release steps", () => { NodeAssert.match(archives, /on:\n {2}workflow_call:/); NodeAssert.match(archives, /^permissions:\n {2}contents: read\n {2}id-token: none/m); NodeAssert.match(archives, /key: linux-x64\n {12}runner: ubuntu-24\.04/); - NodeAssert.match(archives, /key: darwin-arm64\n {12}runner: macos-15/); + // Only the release builds darwin-arm64 on its own Mac (Lazurio/t3code#218); pull requests keep + // GitHub's macos-15, so no pull request's code runs on the machine that builds releases. + NodeAssert.match(archives, /key: darwin-arm64\n {12}runner: \$\{\{ inputs\.darwin_runner \}\}/); + NodeAssert.match(archives, /darwin_runner:\n(?: {8}.*\n)*? {8}default: macos-15\n/); + NodeAssert.match( + release, + /source_sha: \$\{\{ inputs\.source_sha \}\}\n(?: {6}#.*\n)* {6}darwin_runner: lazurio-release-macos\n/, + ); + NodeAssert.doesNotMatch(ci, /darwin_runner/); + NodeAssert.match( + archives, + /name: Launcher install linux-x64\n {4}needs: build\n(?: {4}#.*\n)* {4}if: \$\{\{ !cancelled\(\) \}\}\n/, + ); const stamp = archives.indexOf('node scripts/update-release-package-versions.ts "$VERSION"'); NodeAssert.ok(stamp > 0 && stamp < archives.indexOf("vp run --filter t3 build")); NodeAssert.match(archives, /node apps\/server\/scripts\/cli\.ts build-exe/);