googleapis / release-please-action

automated releases based on conventional commits
Apache License 2.0
1.64k stars 207 forks source link

Race condition when merging main and release PR #1026

Open cekpowell opened 3 weeks ago

cekpowell commented 3 weeks ago

Hey all - loving the action ! Everything is working really nicely in our repo at the moment, we just have one small issue. The steps to produce this issue are as follows:

The result:

Off the back of a release being created, we then check out the commit hash of the release and deploy to our production environment. In this situation, we will end up deploying a commit (the feature that was merged in just before the release PR) to production before it has gone through proper testing.

At the moment, our current solution has been to check the 'require branches to be up to date before merging' option in our branch protection rule. However, this is creating a bad developer experience as now ALL PRs have to be up to date with main before they can be merged in, which means developers are having to resync with main and test multiple times for each PR.

What would be the best approach here ? Would really appreciate some suggestions / help on this one - thanks very much :)