Users are able to merge an open PR even though the source branch has been closed

Issue #14942 open
Pravin Mahendran
staff created an issue

Users are able to merge an open PR even though the source branch has been closed.

Steps to Reproduce - We have 3 branches (master, develop, feature)

  1. Create a PR from the feature branch to the master branch.
  2. Navigate to Branches menu and click on feature branch.
  3. Click "Change Destination" and select develop branch
  4. Click Merge and select close source branch. Proceed with the merge

Now that the source branch is closed, navigate to the created pull request and you will be able to proceed with the merge. You will not be able to update the PR as the source branch no longer exist.

User should not be allowed to close the branch if there's an open PR. Secondly, users should not be allowed to merge the PR as well as the source branch no longer exist.

It would be nice if there could be a notification to users that the source branch no longer exist when an attempt to merge on the open PR.

Comments (4)

  1. Marcus Bertrand staff

    Pull requests that have lost the branch on either side of the potential merge should not allow any actions to take place. In most cases, the Pull request should be automatically declined. We will add this issue to our backlog to fix in the near future.

    Thanks for raising this,
    Marcus

  2. Log in to comment