ci: fix skipped npm publish (manifest output is releases_created) - #40
Merged
Conversation
…runs In manifest mode release-please-action exposes `releases_created` (plural); the singular `release_created` is empty, so the chained publish job was skipped on the 0.3.0 release (release tagged on GitHub, never published to npm).
|
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.



What happened
When PR #38 (release 0.3.0) merged, the Release Please run created
clay-v0.3.0on GitHub but the chainedpublishjob was skipped — so@brika/claywas never pushed to npm (still 0.2.0).Cause
This repo runs release-please in manifest mode (
config-file+manifest-file). In that mode the action exposesreleases_created(plural) andpackages/clay--release_created— not the singularrelease_createdthat #39 referenced.release_createdwas empty, soif: ... release_created == 'true'was false and the publish was skipped.Fix
Use
steps.release.outputs.releases_createdfor the job output. One line.Still required for the auto-publish to authenticate
npm trusted publishing matches the calling workflow filename, which for this chained design is
release-please.yml. Addrelease-please.ymlas a Trusted Publisher for@brika/clayon npmjs.com (keeppublish-npm.ymlfor the manual fallback). See #39 for details.0.3.0 right now
The 0.3.0 GitHub release exists but isn't on npm — publish it via a manual
publish-npmworkflow_dispatch(that path usespublish-npm.ymlas the entry workflow, which is already a trusted publisher).