From fd0ccbd8eaf38a73b6917cfe521a209a5d9af0c7 Mon Sep 17 00:00:00 2001 From: Webster Mudge Date: Mon, 25 Aug 2025 10:48:46 -0400 Subject: [PATCH] Update deprecated actions Signed-off-by: Webster Mudge --- .github/workflows/label_pr.yml | 14 +++++++++++++- .github/workflows/reset_pr.yml | 13 ++++++++++--- .github/workflows/validate_pr.yml | 4 ++-- 3 files changed, 25 insertions(+), 6 deletions(-) diff --git a/.github/workflows/label_pr.yml b/.github/workflows/label_pr.yml index e59a3e54..b8f9a320 100644 --- a/.github/workflows/label_pr.yml +++ b/.github/workflows/label_pr.yml @@ -35,7 +35,7 @@ jobs: github.event.workflow_run.conclusion == 'success' steps: - name: Download the PR number artifact - uses: actions/github-script@v6 + uses: actions/github-script@v7 with: script: | let allArtifacts = await github.rest.actions.listWorkflowRunArtifacts({ @@ -67,3 +67,15 @@ jobs: with: labels: validated number: ${{ steps.read.outputs.pr_number }} + + - name: "Label the PR (replacement)" + uses: "actions/github-script@v7" + with: + script: | + github.rest.issues.addLabels({ + owner: context.repo.owner, + repo: context.repo.repo, + issue_number: context.payload.pull_request.number, + name: 'validated' + }); + if: github.event_name == 'pull_request' diff --git a/.github/workflows/reset_pr.yml b/.github/workflows/reset_pr.yml index befec9fe..8125c601 100644 --- a/.github/workflows/reset_pr.yml +++ b/.github/workflows/reset_pr.yml @@ -34,7 +34,14 @@ jobs: pull-requests: write runs-on: ubuntu-latest steps: - - name: Reset the PR label - uses: actions-ecosystem/action-remove-labels@v1 + - name: "Reset the PR label" + uses: "actions/github-script@v7" with: - labels: validated + script: | + github.rest.issues.removeLabels({ + owner: context.repo.owner, + repo: context.repo.repo, + issue_number: context.payload.pull_request.number, + name: 'validated' + }); + if: github.event_name == 'pull_request' diff --git a/.github/workflows/validate_pr.yml b/.github/workflows/validate_pr.yml index 1bfb7e12..280bbeea 100644 --- a/.github/workflows/validate_pr.yml +++ b/.github/workflows/validate_pr.yml @@ -27,10 +27,10 @@ jobs: runs-on: ubuntu-latest steps: - name: Checkout repository - uses: actions/checkout@v3 + uses: actions/checkout@v4 - name: Setup Python and caching - uses: actions/setup-python@v4 + uses: actions/setup-python@v5 with: python-version: "3.9" cache: "pip"