Skip to content

fix: switch to npm trusted publishing (OIDC) and fix yarn publish bug - #81

Merged
Dhravya merged 6 commits into
mainfrom
vorflux/fix-npm-publish
Apr 17, 2026
Merged

fix: switch to npm trusted publishing (OIDC) and fix yarn publish bug#81
Dhravya merged 6 commits into
mainfrom
vorflux/fix-npm-publish

Conversation

@vorflux

@vorflux vorflux Bot commented Apr 17, 2026

Copy link
Copy Markdown

Summary

Fixes npm publishing which has been failing on every release since v4.18.0, and switches to npm trusted publishing (OIDC) to remove the dependency on NPM_TOKEN secrets.

Root cause (original bug)

bin/publish-npm used yarn publish --tag "$TAG" which targets registry.yarnpkg.com. The Yarn registry is a read-only proxy of npm -- it serves package reads but cannot accept publishes. Every release failed with:

error Couldn't publish package: "https://registry.yarnpkg.com/supermemory: Not found"

Changes

bin/publish-npm:

  • Changed yarn publish --tag "$TAG" to npm publish --tag "$TAG" --provenance
  • Removed npm config set auth token setup (OIDC handles auth)

.github/workflows/publish-npm.yml:

  • Added id-token: write permission for OIDC
  • Added node-version: '24' and registry-url: 'https://registry.npmjs.org' to setup-node
  • Removed NPM_TOKEN env var from publish step (OIDC handles auth)

npm trusted publishing setup required

Configure trusted publisher on npmjs.com for both packages:

Package Repository Workflow Environment
supermemory supermemoryai/sdk-ts publish-npm.yml (blank)
@supermemory/mcp-server supermemoryai/sdk-ts publish-npm.yml (blank)

Testing

This is a shell script fix + workflow update. The fix will be verified on the next release when the publish workflow runs successfully.


Session Details

@vorflux
vorflux Bot enabled auto-merge (squash) April 17, 2026 01:52
@vorflux vorflux Bot changed the title fix: use npm publish instead of yarn publish fix: switch to npm trusted publishing (OIDC) and fix yarn publish bug Apr 17, 2026
Comment thread bin/publish-npm
Comment thread .github/workflows/publish-npm.yml
@Dhravya
Dhravya disabled auto-merge April 17, 2026 02:28
@Dhravya
Dhravya merged commit 2cfab8d into main Apr 17, 2026
10 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant