We recently encountered a bug that resulted us not able to merge our PR in Bitbucket.
Our developer simply re-run the last build with same commit hash after receiving a failed build ❌ . This step created a 2nd build status (see screenshot with 2x LATEST tag).
Bitbucket Server then disallowed the merge button, because there was another failed build for the same commit.
According to the Bitbucket docu, it is storing a build result for each keyandcommit_hash pair.
But the current version was always using the $build_number as the key value. Which means that using "Rebuild" button in Bitrise will always result in adding a new build result entry in Bitbucket --> PRs can't be merged.
My fix is to simply use a more constant value $triggered_workflow_id for the key value.
We recently encountered a bug that resulted us not able to merge our PR in Bitbucket.
Our developer simply re-run the last build with same commit hash after receiving a failed build ❌ . This step created a 2nd build status (see screenshot with 2x
LATEST
tag).Bitbucket Server then disallowed the merge button, because there was another failed build for the same commit.
According to the Bitbucket docu, it is storing a build result for each
key
andcommit_hash
pair.But the current version was always using the
$build_number
as thekey
value. Which means that using "Rebuild" button in Bitrise will always result in adding a new build result entry in Bitbucket --> PRs can't be merged.My fix is to simply use a more constant value
$triggered_workflow_id
for thekey
value.