Skip to content

Commit b749d52

Browse files
avalleteclaude
andauthored
ci(release): add pull-requests permission to release job (#5472)
The release job uses a nested reusable workflow (release-shared.yml) that calls propose-release-notes.yml, which requires `pull-requests: write` permission to create pull requests. For nested reusable workflows, a called job's permissions cannot exceed those granted to the calling job, so this permission must be declared at the release job level even though the propose job uses an App token for its actual PR creation. **Changes:** - Added `pull-requests: write` permission to the release job in `.github/workflows/release.yml` - Added explanatory comments documenting why this permission is required for nested reusable workflows https://claude.ai/code/session_017eKVgHfYw2vb26wX4xh61q Co-authored-by: Claude <noreply@anthropic.com>
1 parent 0ceea0b commit b749d52

1 file changed

Lines changed: 6 additions & 0 deletions

File tree

.github/workflows/release.yml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -189,9 +189,15 @@ jobs:
189189
name: Release
190190
needs: plan
191191
if: needs.plan.outputs.should_release == 'true'
192+
# pull-requests: write is required by the nested propose-release-notes
193+
# workflow (release-shared.yml -> propose-release-notes.yml). For nested
194+
# reusable workflows, a called job's permissions can't exceed those granted
195+
# to the calling job, so this must be declared here even though the propose
196+
# job uses an App token for its actual PR creation.
192197
permissions:
193198
contents: write
194199
id-token: write
200+
pull-requests: write
195201
uses: ./.github/workflows/release-shared.yml
196202
with:
197203
version: ${{ needs.plan.outputs.version }}

0 commit comments

Comments
 (0)