The agent that grows with you
Python aiai-agentai-agentsanthropicchatgptclaudeclaude-codecodexhermeshermes-agentllmnous-researchopenai
fix(release): macOS smoke runs when no receipt was staged
ethernetf546ea2f1d9b
diff --git a/.github/workflows/desktop-bundled-release.yml b/.github/workflows/desktop-bundled-release.ymlindex 75c3aa8517b..769bb2f1587 100644--- a/.github/workflows/desktop-bundled-release.yml+++ b/.github/workflows/desktop-bundled-release.yml@@ -1348,7 +1348,7 @@ jobs:if: >-!cancelled() && needs.validate.result == 'success' && needs.validate.outputs.sha != ''&& needs.build-darwin-arm64.result == 'success' && needs.validate.outputs.darwin-arm64 == 'true'- && needs.stage-receipt-darwin-arm64.result == 'success'+ && (inputs.release-phase != 'candidate' || needs.stage-receipt-darwin-arm64.result == 'success')&& (inputs.release-phase == '' || inputs.release-phase == 'candidate')&& (inputs.upload_release == true || inputs.release-phase == 'candidate' || inputs.build_commit != '' || inputs.channel != '')&& inputs.skip-tests != true@@ -1381,7 +1381,7 @@ jobs:if: >-!cancelled() && needs.validate.result == 'success' && needs.validate.outputs.sha != ''&& needs.build-darwin-x64.result == 'success' && needs.validate.outputs.darwin-x64 == 'true'- && needs.stage-receipt-darwin-x64.result == 'success'+ && (inputs.release-phase != 'candidate' || needs.stage-receipt-darwin-x64.result == 'success')&& (inputs.release-phase == '' || inputs.release-phase == 'candidate')&& (inputs.upload_release == true || inputs.release-phase == 'candidate' || inputs.build_commit != '' || inputs.channel != '')&& inputs.skip-tests != truediff --git a/tests/ci/test_stable_release_graph.py b/tests/ci/test_stable_release_graph.pyindex d2171756994..a57d81ea19c 100644--- a/tests/ci/test_stable_release_graph.py+++ b/tests/ci/test_stable_release_graph.py@@ -427,3 +427,18 @@ def test_the_builds_table_render_cannot_block_the_release_and_has_its_r2_inputs(assert str(step.get("continue-on-error")).lower() == "true" # base YAML loader: a stringassert {"CLOUDFLARE_R2_ACCOUNT_ID", "CLOUDFLARE_R2_ACCESS_KEY_ID", "CLOUDFLARE_R2_SECRET_ACCESS_KEY","CLOUDFLARE_R2_BUCKET", "CLOUDFLARE_R2_PUBLIC_URL", "RELEASE_CLAIM_TAG"} <= set(step["env"])++[email protected]("arch", ["arm64", "x64"])+def test_macos_smoke_runs_without_a_receipt_outside_the_candidate_phase(arch):+ """Only a candidate stages a receipt; a canary's skipped stage-receipt must not skip the smoke,+ or its publish gate (which needs every job to succeed) fails on every canary."""+ smoke = workflow("desktop-bundled-release.yml")["jobs"][f"smoke-darwin-{arch}"]["if"]+ base = {"validate": {"result": "success", "outputs": {"sha": "a" * 40, f"darwin-{arch}": "true"}},+ f"build-darwin-{arch}": {"result": "success"}}+ inputs = {"release-phase": "", "upload_release": True, "skip-tests": False}+ skipped = {**base, f"stage-receipt-darwin-{arch}": {"result": "skipped"}}+ staged = {**base, f"stage-receipt-darwin-{arch}": {"result": "success"}}+ assert gate(smoke, inputs, skipped)+ assert not gate(smoke, {**inputs, "release-phase": "candidate"}, skipped)+ assert gate(smoke, {**inputs, "release-phase": "candidate"}, staged)