Commit 16b1719
fix(template): Make "Finished Build and Publish" gate reflect real build outcome
The `finished` job is the single required status check for the build
workflow. It had no `if:` clause, so a failed dependency caused GitHub to
*skip* it rather than fail it - and branch protection treats a skipped
required check as passing. A broken build (e.g. a failed
publish-index-manifest) therefore became mergeable.
Two fixes:
- Add `if: always()` so the gate always runs and reports a real
success/failure conclusion.
- List every leaf job directly in `needs` and fail the gate on any
`failure`/`cancelled` result. Previously publish-index-manifest was only
a transitive dependency (via openshift-preflight-check), so its failure
would not surface in `needs.*.result`. `skipped` is tolerated, since jobs
skip legitimately on merge_group events, forks, and when detect-changes
finds no relevant changes.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>1 parent 272b393 commit 16b1719
1 file changed
Lines changed: 30 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
372 | 372 | | |
373 | 373 | | |
374 | 374 | | |
| 375 | + | |
| 376 | + | |
| 377 | + | |
| 378 | + | |
| 379 | + | |
| 380 | + | |
| 381 | + | |
| 382 | + | |
| 383 | + | |
375 | 384 | | |
| 385 | + | |
376 | 386 | | |
377 | | - | |
| 387 | + | |
| 388 | + | |
| 389 | + | |
| 390 | + | |
378 | 391 | | |
| 392 | + | |
379 | 393 | | |
380 | 394 | | |
381 | | - | |
| 395 | + | |
| 396 | + | |
| 397 | + | |
| 398 | + | |
| 399 | + | |
| 400 | + | |
| 401 | + | |
| 402 | + | |
| 403 | + | |
| 404 | + | |
| 405 | + | |
| 406 | + | |
| 407 | + | |
| 408 | + | |
| 409 | + | |
382 | 410 | | |
383 | 411 | | |
384 | 412 | | |
| |||
0 commit comments