Skip to content

Commit 6a78a0b

Browse files
fix: prevent duplicate release PRs with concurrency group (#397)
Add concurrency control to release-plz workflow to prevent race condition where merging a release PR triggers another workflow run that creates a duplicate release PR before the first run completes publishing. The race happens because: 1. Merge release PR -> triggers release-plz run 2. Main branch update -> triggers another release-plz run 3. Second run checks state before first completes 4. Creates duplicate PR for same version Solution: Only allow one release-plz run at a time with cancel-in-progress: false to ensure the first run completes before the next one starts.
1 parent abd180f commit 6a78a0b

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

.github/workflows/release-plz.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,10 @@ on:
99
branches:
1010
- main
1111

12+
concurrency:
13+
group: release-plz
14+
cancel-in-progress: false
15+
1216
jobs:
1317
release-plz:
1418
name: Release-plz

0 commit comments

Comments
 (0)