Skip to content

Conversation

Copy link
Contributor

Copilot AI commented Oct 13, 2025

Problem

The Release workflow was failing with a 404 error when attempting to publish packages to NPM:

npm error 404 Not Found - PUT https://registry.npmjs.org/supergrain
npm error 404 The requested resource 'supergrain@0.9.0' could not be found or you do not have permission to access it.

The workflow was attempting to publish the root supergrain package (unscoped) to NPM, which doesn't exist and shouldn't be published. Only the scoped packages (@supergrain/core, @supergrain/react, @supergrain/store) should be published.

Solution

Added "private": true to the root package.json. This tells pnpm to skip the root package when running pnpm -r publish, ensuring only the publishable scoped packages are sent to NPM.

Before:

{
  "name": "supergrain",
  "version": "0.9.0",
  "description": "",
  ...
}

After:

{
  "name": "supergrain",
  "version": "0.9.0",
  "private": true,
  "description": "",
  ...
}

Testing

Verified with pnpm -r publish --dry-run that only the three scoped packages will be published:

  • @supergrain/core@0.1.0
  • @supergrain/react@0.3.0
  • @supergrain/store@0.1.0

The root supergrain package is correctly excluded from publishing.

Documentation Updates

Updated NPM_SETUP.md and NPM_PUBLISHING_CHECKLIST.md to document that the root package is marked as private, helping future maintainers understand this configuration.

Answer to "Do I need to create the packages outside of GitHub?"

No! The GitHub Actions workflow is correctly configured. The only issue was the missing "private": true field. With this fix, the automated release workflow will work as designed:

  1. Create changesets for your changes
  2. Merge changesets to trigger release PR creation
  3. Merge the release PR to automatically publish to NPM

No manual package publishing is required.

Original prompt

The Release workflow still didn't work. Do I need to create the packages outside of github?


💬 Share your feedback on Copilot coding agent for the chance to win a $200 gift card! Click here to start the survey.

Copilot AI and others added 2 commits October 13, 2025 14:28
Co-authored-by: scottmessinger <100121+scottmessinger@users.noreply.github.com>
Co-authored-by: scottmessinger <100121+scottmessinger@users.noreply.github.com>
Copilot AI changed the title [WIP] Fix issues in the release workflow Fix release workflow by marking root package as private Oct 13, 2025
Copilot AI requested a review from scottmessinger October 13, 2025 14:33
@scottmessinger scottmessinger marked this pull request as ready for review October 13, 2025 16:21
@scottmessinger scottmessinger merged commit b521a08 into main Oct 13, 2025
3 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.

2 participants