You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Two changes:
1. Added a "Diagnose OIDC token claims" step to publish-ts that
fetches the OIDC token with audience=npm:registry.npmjs.org
and decodes the payload, printing sub/repository/job_workflow_ref/
environment/ref. This tells us exactly what claims npm sees and
whether they match the trusted-publisher config.
Background: v3.8.2 retry on npm still ENEEDAUTH'd even with
npm 11.16.0 (well above 11.5.1 OIDC minimum). Hypothesis: when
publish.yml runs via workflow_call from
auto-release-on-version-bump.yml, the job_workflow_ref claim
may point at the calling workflow rather than publish.yml,
and npm's trusted-publisher is exact-match on filename.
2. Removed the standalone `approval` job. It had
environment: release which triggered a separate approval prompt
in addition to the prompts on publish-py/publish-ts. Now publish-py
and publish-ts gate themselves on the env (one prompt covers both
since they're parallel), and each logs the actual approver as its
first step using /actions/runs/{id}/approvals (which requires
actions: read permission, added).
Both jobs' needs changed from [preflight, approval] to [preflight].
echo "::notice::Release approved by @${APPROVER} for release ${RELEASE_TAG} (v${TARGET_VERSION}). Triggered by @${GITHUB_ACTOR}. Run ${GITHUB_RUN_ID}."
157
-
echo "Approver: @${APPROVER}"
158
-
echo "Triggered by: @${GITHUB_ACTOR}"
159
-
echo "Release tag: ${RELEASE_TAG}"
160
-
echo "Version: ${TARGET_VERSION}"
161
-
162
-
publish-py:
163
-
name: Publish Python SDK to PyPI
164
-
needs: [preflight, approval]
165
-
environment: release
166
-
runs-on: ubuntu-latest
167
-
permissions:
168
-
id-token: write # required for PyPI trusted publishing OIDC
0 commit comments