From da1c7f7becfe6648e54e2a69a6672ad60c499162 Mon Sep 17 00:00:00 2001 From: Shweta Singh Date: Thu, 11 Apr 2024 14:23:15 +0530 Subject: [PATCH] Update PRT Label Remove (#14707) Update PRT Level Remove (cherry picked from commit d110fcda62e694646e1dcfb6844fc5729a69ed52) --- .github/workflows/prt_labels.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/prt_labels.yml b/.github/workflows/prt_labels.yml index 52dd68589b3..072a46ba196 100644 --- a/.github/workflows/prt_labels.yml +++ b/.github/workflows/prt_labels.yml @@ -8,7 +8,7 @@ jobs: prt_labels_remover: name: remove the PRT label when amendments or new commits added to PR runs-on: ubuntu-latest - if: "(contains(github.event.pull_request.labels.*.name, 'PRT-Passed') || contains(github.event.pull_request.labels.*.name, 'PRT-Failed'))" + if: "(contains(github.event.pull_request.labels.*.name, 'PRT-Passed'))" steps: - name: Avoid the race condition as PRT result will be cleaned run: | @@ -23,7 +23,7 @@ jobs: wait-interval: 2 count: 5 - - name: remove the PRT Passed/Failed label, for new commit + - name: remove the PRT Passed label, for new commit if: always() && ${{steps.prt.outputs.result}} == 'not_found' uses: actions/github-script@v7 with: @@ -35,7 +35,7 @@ jobs: repo: context.repo.repo, issue_number: prNumber, }); - const labelsToRemove = ['PRT-Failed', 'PRT-Passed']; + const labelsToRemove = ['PRT-Passed']; const labelsToRemoveFiltered = labelsToRemove.filter(label => issue.data.labels.some(({ name }) => name === label)); if (labelsToRemoveFiltered.length > 0) { await Promise.all(labelsToRemoveFiltered.map(async label => {