From 823880ddb86cebe57d971cbd5c72d9e79c6b5e0c Mon Sep 17 00:00:00 2001 From: Lucas Bedatty Date: Thu, 26 Mar 2026 10:21:45 -0300 Subject: [PATCH 1/4] fix(pr-validation): pin composite refs to v1.20.0 --- .github/workflows/pr-validation.yml | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/.github/workflows/pr-validation.yml b/.github/workflows/pr-validation.yml index bb7c28b..ea67217 100644 --- a/.github/workflows/pr-validation.yml +++ b/.github/workflows/pr-validation.yml @@ -93,7 +93,7 @@ jobs: id: source-branch if: inputs.enforce_source_branches continue-on-error: true - uses: LerianStudio/github-actions-shared-workflows/src/validate/pr-source-branch@v1.20.0-beta.1 + uses: LerianStudio/github-actions-shared-workflows/src/validate/pr-source-branch@v1.20.0 with: github-token: ${{ secrets.MANAGE_TOKEN || github.token }} allowed-branches: ${{ inputs.allowed_source_branches }} @@ -103,7 +103,7 @@ jobs: - name: Validate PR title id: title continue-on-error: true - uses: LerianStudio/github-actions-shared-workflows/src/validate/pr-title@v1.20.0-beta.1 + uses: LerianStudio/github-actions-shared-workflows/src/validate/pr-title@v1.20.0 with: github-token: ${{ github.token }} types: ${{ inputs.pr_title_types }} @@ -113,7 +113,7 @@ jobs: - name: Validate PR description id: description continue-on-error: true - uses: LerianStudio/github-actions-shared-workflows/src/validate/pr-description@v1.20.0-beta.1 + uses: LerianStudio/github-actions-shared-workflows/src/validate/pr-description@v1.20.0 with: min-length: ${{ inputs.min_description_length }} @@ -161,7 +161,7 @@ jobs: - name: Check PR metadata id: metadata continue-on-error: true - uses: LerianStudio/github-actions-shared-workflows/src/validate/pr-metadata@v1.20.0-beta.1 + uses: LerianStudio/github-actions-shared-workflows/src/validate/pr-metadata@v1.20.0 with: github-token: ${{ secrets.MANAGE_TOKEN || github.token }} dry-run: ${{ inputs.dry_run && 'true' || 'false' }} @@ -169,7 +169,7 @@ jobs: - name: Check PR size id: size continue-on-error: true - uses: LerianStudio/github-actions-shared-workflows/src/validate/pr-size@v1.20.0-beta.1 + uses: LerianStudio/github-actions-shared-workflows/src/validate/pr-size@v1.20.0 with: github-token: ${{ secrets.MANAGE_TOKEN || github.token }} base-ref: ${{ github.base_ref }} @@ -179,7 +179,7 @@ jobs: id: labels if: inputs.enable_auto_labeler && !inputs.dry_run continue-on-error: true - uses: LerianStudio/github-actions-shared-workflows/src/validate/pr-labels@v1.20.0-beta.1 + uses: LerianStudio/github-actions-shared-workflows/src/validate/pr-labels@v1.20.0 with: github-token: ${{ secrets.MANAGE_TOKEN || github.token }} config-path: ${{ inputs.labeler_config_path }} @@ -202,7 +202,7 @@ jobs: steps: - name: PR Checks Summary - uses: LerianStudio/github-actions-shared-workflows/src/validate/pr-checks-summary@v1.20.0-beta.1 + uses: LerianStudio/github-actions-shared-workflows/src/validate/pr-checks-summary@v1.20.0 with: source-branch-result: ${{ needs.blocking-checks.outputs.source-branch-result || 'skipped' }} title-result: ${{ needs.blocking-checks.outputs.title-result || 'skipped' }} @@ -217,7 +217,7 @@ jobs: name: Notify needs: [blocking-checks, advisory-checks, pr-checks-summary] if: always() && github.event.pull_request.draft != true && !inputs.dry_run - uses: LerianStudio/github-actions-shared-workflows/.github/workflows/slack-notify.yml@v1.20.0-beta.1 + uses: LerianStudio/github-actions-shared-workflows/.github/workflows/slack-notify.yml@v1.20.0 with: status: ${{ (needs.blocking-checks.outputs.source-branch-result == 'failure' || needs.blocking-checks.outputs.title-result == 'failure' || needs.blocking-checks.outputs.description-result == 'failure') && 'failure' || 'success' }} workflow_name: "PR Validation" From 55d36b32dda11f2c6964ac434e64086e4e6ddae7 Mon Sep 17 00:00:00 2001 From: Lucas Bedatty Date: Thu, 26 Mar 2026 11:07:00 -0300 Subject: [PATCH 2/4] fix(pr-blocking-collect): add README and pin ref to v1.20.0 --- .github/workflows/pr-validation.yml | 26 +++---------- src/validate/pr-blocking-collect/README.md | 43 ++++++++++++++++++++++ 2 files changed, 48 insertions(+), 21 deletions(-) create mode 100644 src/validate/pr-blocking-collect/README.md diff --git a/.github/workflows/pr-validation.yml b/.github/workflows/pr-validation.yml index ea67217..4a4f7ce 100644 --- a/.github/workflows/pr-validation.yml +++ b/.github/workflows/pr-validation.yml @@ -119,27 +119,11 @@ jobs: - name: Collect results and enforce blocking id: collect - run: | - SOURCE_BRANCH="${{ steps.source-branch.outcome || 'skipped' }}" - TITLE="${{ steps.title.outcome }}" - DESCRIPTION="${{ steps.description.outcome }}" - - { - echo "source_branch=${SOURCE_BRANCH}" - echo "title=${TITLE}" - echo "description=${DESCRIPTION}" - } >> "$GITHUB_OUTPUT" - - # Fail the job if any blocking check failed - FAILED="" - if [ "${SOURCE_BRANCH}" = "failure" ]; then FAILED="${FAILED} source-branch"; fi - if [ "${TITLE}" = "failure" ]; then FAILED="${FAILED} title"; fi - if [ "${DESCRIPTION}" = "failure" ]; then FAILED="${FAILED} description"; fi - - if [ -n "${FAILED}" ]; then - echo "::error::Blocking checks failed:${FAILED}" - exit 1 - fi + uses: LerianStudio/github-actions-shared-workflows/src/validate/pr-blocking-collect@v1.20.0 + with: + source-branch-outcome: ${{ steps.source-branch.outcome || 'skipped' }} + title-outcome: ${{ steps.title.outcome }} + description-outcome: ${{ steps.description.outcome }} # ----------------- Tier 2: Advisory Checks (shared checkout, depends on Tier 1) ----------------- advisory-checks: diff --git a/src/validate/pr-blocking-collect/README.md b/src/validate/pr-blocking-collect/README.md new file mode 100644 index 0000000..91aa7e6 --- /dev/null +++ b/src/validate/pr-blocking-collect/README.md @@ -0,0 +1,43 @@ + + + + + +
Lerian

pr-blocking-collect

+ +Collects outcomes from blocking validation checks, writes them as job outputs, and fails the job if any check failed. Used as the final step in the blocking-checks tier of the pr-validation workflow. + +## Inputs + +| Input | Description | Required | Default | +|-------|-------------|----------|---------| +| `source-branch-outcome` | Outcome of the source branch validation step | No | `skipped` | +| `title-outcome` | Outcome of the PR title validation step | Yes | | +| `description-outcome` | Outcome of the PR description validation step | Yes | | + +## Outputs + +| Output | Description | +|--------|-------------| +| `source_branch` | Outcome of source branch validation | +| `title` | Outcome of PR title validation | +| `description` | Outcome of PR description validation | + +## Usage as composite step + +```yaml +- name: Collect results and enforce blocking + id: collect + uses: LerianStudio/github-actions-shared-workflows/src/validate/pr-blocking-collect@v1.x.x + with: + source-branch-outcome: ${{ steps.source-branch.outcome || 'skipped' }} + title-outcome: ${{ steps.title.outcome }} + description-outcome: ${{ steps.description.outcome }} +``` + +## Required permissions + +```yaml +permissions: + contents: read +``` From bd7fc56ac3f3001fcfa24460c4ca17f0e7e3472d Mon Sep 17 00:00:00 2001 From: Lucas Bedatty Date: Thu, 26 Mar 2026 11:13:34 -0300 Subject: [PATCH 3/4] fix(pr-blocking-collect): use branch ref for testing --- .github/workflows/pr-validation.yml | 2 +- src/validate/pr-blocking-collect/action.yml | 52 +++++++++++++++++++++ 2 files changed, 53 insertions(+), 1 deletion(-) create mode 100644 src/validate/pr-blocking-collect/action.yml diff --git a/.github/workflows/pr-validation.yml b/.github/workflows/pr-validation.yml index 4a4f7ce..11b997a 100644 --- a/.github/workflows/pr-validation.yml +++ b/.github/workflows/pr-validation.yml @@ -119,7 +119,7 @@ jobs: - name: Collect results and enforce blocking id: collect - uses: LerianStudio/github-actions-shared-workflows/src/validate/pr-blocking-collect@v1.20.0 + uses: LerianStudio/github-actions-shared-workflows/src/validate/pr-blocking-collect@fix/pin-refs-v1.20.0 with: source-branch-outcome: ${{ steps.source-branch.outcome || 'skipped' }} title-outcome: ${{ steps.title.outcome }} diff --git a/src/validate/pr-blocking-collect/action.yml b/src/validate/pr-blocking-collect/action.yml new file mode 100644 index 0000000..ea8b7b5 --- /dev/null +++ b/src/validate/pr-blocking-collect/action.yml @@ -0,0 +1,52 @@ +name: PR Blocking Collect +description: "Collects outcomes from blocking checks, writes them to GITHUB_OUTPUT, and fails the job if any check failed." + +inputs: + source-branch-outcome: + description: Outcome of the source branch validation step + required: false + default: skipped + title-outcome: + description: Outcome of the PR title validation step + required: true + description-outcome: + description: Outcome of the PR description validation step + required: true + +outputs: + source_branch: + description: Outcome of source branch validation + value: ${{ steps.collect.outputs.source_branch }} + title: + description: Outcome of PR title validation + value: ${{ steps.collect.outputs.title }} + description: + description: Outcome of PR description validation + value: ${{ steps.collect.outputs.description }} + +runs: + using: composite + steps: + - name: Collect and enforce + id: collect + shell: bash + env: + SOURCE_BRANCH: ${{ inputs.source-branch-outcome }} + TITLE: ${{ inputs.title-outcome }} + DESCRIPTION: ${{ inputs.description-outcome }} + run: | + { + echo "source_branch=${SOURCE_BRANCH}" + echo "title=${TITLE}" + echo "description=${DESCRIPTION}" + } >> "$GITHUB_OUTPUT" + + FAILED="" + if [ "${SOURCE_BRANCH}" = "failure" ]; then FAILED="${FAILED} source-branch"; fi + if [ "${TITLE}" = "failure" ]; then FAILED="${FAILED} title"; fi + if [ "${DESCRIPTION}" = "failure" ]; then FAILED="${FAILED} description"; fi + + if [ -n "${FAILED}" ]; then + echo "::error::Blocking checks failed:${FAILED}" + exit 1 + fi From b4f95c93f10564c4cf137a6d5a8e460396902255 Mon Sep 17 00:00:00 2001 From: Lucas Bedatty Date: Thu, 26 Mar 2026 11:17:57 -0300 Subject: [PATCH 4/4] =?UTF-8?q?docs(pr-blocking-collect):=20fix=20terminol?= =?UTF-8?q?ogy=20=E2=80=94=20step=20outputs,=20not=20job=20outputs?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/validate/pr-blocking-collect/README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/validate/pr-blocking-collect/README.md b/src/validate/pr-blocking-collect/README.md index 91aa7e6..09edab6 100644 --- a/src/validate/pr-blocking-collect/README.md +++ b/src/validate/pr-blocking-collect/README.md @@ -5,7 +5,7 @@ -Collects outcomes from blocking validation checks, writes them as job outputs, and fails the job if any check failed. Used as the final step in the blocking-checks tier of the pr-validation workflow. +Collects outcomes from blocking validation checks, exposes them as step outputs, and fails the job if any check failed. Used as the final step in the blocking-checks tier of the pr-validation workflow. ## Inputs