From 4cd9833d7c5cdbaa57ffb2c2c73bda265b5ea98d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pawe=C5=82=20Gronowski?= Date: Thu, 14 Aug 2025 12:50:00 +0200 Subject: [PATCH] gha/validate-pr: Replace `continue-on-error` MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The label validation steps now properly fail the workflow when required labels are missing, instead of continuing with errors. This change removes the `continue-on-error: true` directives and adds `always()` conditions to ensure the validation steps run regardless of previous step outcomes. Signed-off-by: Paweł Gronowski --- .github/workflows/validate-pr.yml | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/.github/workflows/validate-pr.yml b/.github/workflows/validate-pr.yml index 0b931b9ce..6a04aca05 100644 --- a/.github/workflows/validate-pr.yml +++ b/.github/workflows/validate-pr.yml @@ -19,14 +19,12 @@ jobs: timeout-minutes: 120 # guardrails timeout for the whole job steps: - name: Missing `area/` label - continue-on-error: true - if: contains(join(github.event.pull_request.labels.*.name, ','), 'impact/') && !contains(join(github.event.pull_request.labels.*.name, ','), 'area/') + if: always() && contains(join(github.event.pull_request.labels.*.name, ','), 'impact/') && !contains(join(github.event.pull_request.labels.*.name, ','), 'area/') run: | echo "::error::Every PR with an 'impact/*' label should also have an 'area/*' label" exit 1 - name: Missing `kind/` label - continue-on-error: true - if: contains(join(github.event.pull_request.labels.*.name, ','), 'impact/') && !contains(join(github.event.pull_request.labels.*.name, ','), 'kind/') + if: always() && contains(join(github.event.pull_request.labels.*.name, ','), 'impact/') && !contains(join(github.event.pull_request.labels.*.name, ','), 'kind/') run: | echo "::error::Every PR with an 'impact/*' label should also have a 'kind/*' label" exit 1