Skip to content

Commit 27e19f4

Browse files
TheGupta2012claude
andcommitted
ci: move id-token permission to the publishing job
The permissions block landed on build_sdist, which only builds an sdist. The pypi-publish job runs gh-action-pypi-publish and had no permissions at all, so ACTIONS_ID_TOKEN_REQUEST_TOKEN was unset and the OIDC exchange failed. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
1 parent d8bc0e6 commit 27e19f4

2 files changed

Lines changed: 6 additions & 6 deletions

File tree

.github/workflows/pre-release.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -123,9 +123,6 @@ jobs:
123123
build_sdist:
124124
name: Source distribution
125125
runs-on: ubuntu-latest
126-
permissions:
127-
id-token: write # mint the OIDC token PyPI trusted publishing verifies
128-
contents: read # actions/checkout
129126

130127
steps:
131128
- name: Checkout Pyqasm
@@ -160,6 +157,9 @@ jobs:
160157
needs: [build_wheels, build_sdist]
161158
runs-on: ubuntu-latest
162159
environment: release
160+
permissions:
161+
id-token: write # mint the OIDC token PyPI trusted publishing verifies
162+
contents: read # actions/checkout
163163

164164
steps:
165165
- name: Checkout Pyqasm

.github/workflows/release.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -119,9 +119,6 @@ jobs:
119119
build_sdist:
120120
name: Source distribution
121121
runs-on: ubuntu-latest
122-
permissions:
123-
id-token: write # mint the OIDC token PyPI trusted publishing verifies
124-
contents: read # actions/checkout
125122

126123
steps:
127124
- name: Checkout PyQASM
@@ -151,6 +148,9 @@ jobs:
151148
needs: [build_wheels, build_sdist]
152149
runs-on: ubuntu-latest
153150
environment: release
151+
permissions:
152+
id-token: write # mint the OIDC token PyPI trusted publishing verifies
153+
contents: read # actions/checkout
154154

155155
steps:
156156
- name: Checkout PyQASM

0 commit comments

Comments
 (0)