From 12e4b5a646c66e1bf19dc8dd3290c2e8fc7b2af4 Mon Sep 17 00:00:00 2001 From: Pieter Viljoen Date: Fri, 16 Oct 2026 10:57:31 -0700 Subject: [PATCH 1/2] Let a Manual Dispatch Bypass the Smoke Build's Paths Filter A workflow_dispatch run has no changed paths to filter, so the paths-filter job reports no release change and the smoke build was always skipped. A manual run is an explicit ask to build, so smoke-build now runs on a dispatch or on a filtered change, in the catalog snippet and its documented copy together. Fixes #3149 Co-Authored-By: Claude Sonnet 5.5 --- catalog/snippets/workflows/test-pull-request-smoke.yml | 2 +- docs/reusable-workflows.md | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/catalog/snippets/workflows/test-pull-request-smoke.yml b/catalog/snippets/workflows/test-pull-request-smoke.yml index f4c8c0d0..0a5c47f1 100644 --- a/catalog/snippets/workflows/test-pull-request-smoke.yml +++ b/catalog/snippets/workflows/test-pull-request-smoke.yml @@ -51,7 +51,7 @@ jobs: smoke-build: name: Smoke build job needs: [changes] - if: needs.changes.outputs.release == 'true' + if: github.event_name == 'workflow_dispatch' || needs.changes.outputs.release == 'true' uses: ptr727/ProjectTemplate/.github/workflows/build-release-task.yml@6c88850128629bb449fd73c7fbf82968c6cd1557 # 2.0.587 permissions: contents: read diff --git a/docs/reusable-workflows.md b/docs/reusable-workflows.md index b2b37669..9b7dab5a 100644 --- a/docs/reusable-workflows.md +++ b/docs/reusable-workflows.md @@ -355,7 +355,7 @@ jobs: smoke-build: name: Smoke build job needs: [changes] - if: needs.changes.outputs.release == 'true' + if: github.event_name == 'workflow_dispatch' || needs.changes.outputs.release == 'true' uses: ptr727/ProjectTemplate/.github/workflows/build-release-task.yml@6c88850128629bb449fd73c7fbf82968c6cd1557 # 2.0.587 permissions: contents: read From ad96f59bd06b0e550e67f2311716a15a20f1e3ab Mon Sep 17 00:00:00 2001 From: Pieter Viljoen Date: Fri, 16 Oct 2026 11:03:37 -0700 Subject: [PATCH 2/2] Assert the Smoke Stub's Dispatch Bypass in Its Test The byte-for-byte test only proved the snippet and its documented copy match, so reverting both to a filter-only condition still passed. It now also asserts the smoke-build condition carries the workflow_dispatch bypass. Co-Authored-By: Claude Sonnet 5.5 --- tests/test_release_guards.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/tests/test_release_guards.py b/tests/test_release_guards.py index fc66f118..79c30d7c 100755 --- a/tests/test_release_guards.py +++ b/tests/test_release_guards.py @@ -722,6 +722,10 @@ def test_smoke_caller_stub_is_its_snippet_byte_for_byte(self) -> None: blocks = yaml_blocks((REPO / "docs/reusable-workflows.md").read_text(encoding="utf-8")) self.assertIn(stub, blocks) self.assertIn("smoke: true", stub) + self.assertIn( + " if: github.event_name == 'workflow_dispatch' || needs.changes.outputs.release == 'true'\n", + stub, + ) def test_release_asset_hook_upload_stays_with_the_task(self) -> None: workflow = (REPO / ".github/workflows/build-release-task.yml").read_text(encoding="utf-8")