ci: skip release PR generation when a release was just created - #3120
Merged
Conversation
|
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
Merging the 7.2.0 release PR created a bogus
7.3.0PR (#3119) whose changelog regenerates from months-old commits — the same failure #3108 was meant to prevent.Timeline from the run:
Two distinct problems:
gh api .../releases, but that check runs ~2 seconds after phase 1 creates the draft, and the list endpoint hadn't reflected it yet. Zero drafts reported, so the release-PR phase ran.v7.2.0is a 404 right now), so release-please logs "No latest release pull request found" and rebuilds the changelog from the beginning of history.Changes
Gate on release-please's own output rather than an API read:
release_createdcomes from the same action invocation that created the draft, so it cannot race. The existing draft-count check is kept as the second condition — it covers drafts left pending by earlier runs, where the API has long since caught up.concurrencygroup on the workflow. Releases now serialise. Overlapping runs are how the sibling repo ended up with a version tagged on GitHub but never published to npm, and this workflow had no protection against it.Effect
release_created == 'true'#3119 should be closed; it will be regenerated correctly once v7.2.0 publishes and its tag materialises.