Conversation
Mrtenz
reviewed
Jun 9, 2026
| @@ -1,2 +1,2 @@ | |||
| name: Publish Release | |||
|
|
|||
Member
There was a problem hiding this comment.
Missing top-level permissions. Take a look at the core workflow for example:
Mrtenz
reviewed
Jun 9, 2026
Member
There was a problem hiding this comment.
main.yml also needs to be updated to have id-token: write permission when calling this workflow.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Explanation
Core Platform is hardening MetaMask's NPM supply chain by replacing long-lived NPM tokens with trusted publishing (OIDC) plus staged publishing. All package owners must move to
MetaMask/action-npm-publish@v6, which implements those changes. This covers all six non-private@metamask/connectpackages published from this monorepo (connect,connect-evm,connect-solana,connect-multichain,multichain-ui,analytics).Previously the release workflow published with
action-npm-publish@v5using a required, long-livedNPM_TOKENand noid-token: writepermission. This PR migrates the release publishing path to OIDC trusted publishing:publish-release.ymlfromaction-npm-publish@v5to@v6.publish-npmjobpermissions: id-token: write(withcontents: read) so it can request the OIDC token used by trusted publishing.NPM_TOKENsecret optional (required: false) rather than required. The token is still passed to the publish step as the fallback / first-publish path, per the MetaMask module template.packageManagertoyarn@4.16.0(latest stable; the previous4.9.2was below the>= 4.16.0requirement). This also bumps theyarn.lockmetadata format fromversion: 8to10.Scope notes
action-checkout-and-setup/download-artifactwere intentionally left untouched. Only the npm-publish action bump is required by the acceptance criteria; bumping the other helper actions is unrelated scope and is better handled separately.publish-preview.ymlis out of scope. It publishes preview builds to GitHub Packages via a dedicatedPUBLISH_PREVIEW_NPM_TOKEN, and NPM trusted publishing (OIDC) is an npmjs.com registry feature that does not apply to GitHub Packages.SKIP_PREPACKwas added (present in the module template) because none of the packages define aprepackscript, so it would be a no-op here.Verification
yarn install --immutablepasses cleanly on Yarn 4.16.0.yarn buildpasses (11/11 tasks).Important
Trusted publishing must be enabled on the npm side for all six packages by the @metamask-npm-publishers team before the first OIDC-based release. Until then, publishing continues to rely on the (now optional)
NPM_TOKEN.References
Checklist