From 789b2a0bd8c245274105ba57a7146cd4fdf4f7a8 Mon Sep 17 00:00:00 2001 From: Martin Tzvetanov Grigorov Date: Tue, 20 Aug 2024 09:39:12 +0300 Subject: [PATCH] Add "pull-requests: write" permission to the labeler Copied from the example at https://github.com/actions/labeler?tab=readme-ov-file#outputs Trying to fix https://github.com/apache/avro/actions/runs/10460767435/job/28981928566?pr=3102 ``` Run actions/labeler@v5 with: repo-token: *** sync-labels: true configuration-path: .github/labeler.yml dot: true The configuration file (path: .github/labeler.yml) was not found locally, fetching via the api Warning: The action requires write permission to add labels to pull requests. For more information please refer to the action documentation: https://github.com/actions/labeler#permissions Error: Resource not accessible by integration ``` Signed-off-by: Martin Tzvetanov Grigorov --- .github/workflows/labeler.yml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.github/workflows/labeler.yml b/.github/workflows/labeler.yml index 815d5d02a5c..53280443d29 100644 --- a/.github/workflows/labeler.yml +++ b/.github/workflows/labeler.yml @@ -21,6 +21,9 @@ on: pull_request_target jobs: triage: + permissions: + contents: read + pull-requests: write runs-on: ubuntu-latest steps: - uses: actions/labeler@v5