From 2efe0c95e63817f312f5fb12cc60dd56bee0023b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bart=C5=82omiej=20Dach?= Date: Fri, 6 Feb 2026 12:22:53 +0100 Subject: [PATCH] Fix "copy labels from issues" workflow not having the appropriate permissions to do what it claims to do (#36602) --- .github/workflows/pull-request-copy-labels.yml | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/.github/workflows/pull-request-copy-labels.yml b/.github/workflows/pull-request-copy-labels.yml index b1309b29c5..8953376441 100644 --- a/.github/workflows/pull-request-copy-labels.yml +++ b/.github/workflows/pull-request-copy-labels.yml @@ -1,13 +1,19 @@ +name: Copy labels from linked issues + on: pull_request: types: [opened] +permissions: + issues: write # to read the labels of any linked issue(s), and to put the found labels if any on the PR + # not granting any `pull_requests` permissions because in github's modeling pull requests are a subset of issues. it's confusing. + jobs: copy-labels: runs-on: ubuntu-latest name: Copy labels from linked issues steps: - - name: copy-labels + - name: Copy labels uses: michalvankodev/copy-issue-labels@v1.3.0 with: repo-token: ${{ secrets.GITHUB_TOKEN }}