Changing the destination branch of a pull request fails to trigger unapprovals
Issue #8
resolved
It appears the approval trigger only exists on new commits to the source branch of the pull request, but when someone edits the pull request and changes the destination branch of the pull request approvals are not reset.
Use Case: Developer submits a pull request into a future release then proceeds to get all the required approvals on the pull request... before merging the developer edits the pull request to go into the current release branch then immediately merges it into a branch that there were no approvals for.
Comments (3)
-
Account Deleted reporter -
Account Deactivated -
assigned issue to
-
assigned issue to
-
- changed status to resolved
This bug has now been addressed in the latest release of the plugin, please see version 2.0.4 for the fix.
- Log in to comment
I'm not sure why, but despite this feeling like a bug, it appears like was intentional. The code in the rescopeEventListener has this line {code} // only withdraw approval if the pull request's source branch has changed, not it's target. if (!event.getPreviousFromHash().equals(pullRequest.getFromRef().getLatestChangeset()) {code} Removing the comment and the conditional check will fix this problem.