vscode-pull-request-github icon indicating copy to clipboard operation
vscode-pull-request-github copied to clipboard

Create PR shows error if there has been a previous PR on that branch

Open trinkel opened this issue 7 months ago • 1 comments

Version info

  • Extension version: 0.110.0
  • VSCode Version: 1.100.3
  • OS: MacOS 16.3.2
  • Repository Clone Configuration (single repository/fork of an upstream repository): Single original repository
  • Github Product (Github.com/Github Enterprise version x.x.x): Github.com

Steps to Reproduce:

In the Create Pull Request dialog

  1. Create PR from, for example, development branch to main branch`, merge and close.
  2. Create additional commits.
  3. Create a new PR from development branch to main branch`.
  4. RESULT: At the bottom of the description box is an error: "A pull request already exists for this branch."

My workflow is to have a main branch, and a development branch. To work on a feature, I create feature branch. When that is complete, it is merged into the development branch. When a milestone is ready to deploy, the development branch is merged into the main branch by way of a pull request. This process is repeated throughout the life of the project so development may be merged into main many times. However, there is never more than one PR open on the same branch at a time.

I believe I have been able to do this in the past. I can create PRs in GitHub for the same branch without an error.

Is this something that is new in recent releases, or am I going crazy and it's always been like that?

Image

trinkel avatar Jun 07 '25 19:06 trinkel

In some cases it will default to a comment that it is reverting a previous commit. In the case of this screenshot, a commit from seven months ago. If it's true, it is certainly not what I want to due. If not, it is, at best, misleading.

Image

alt text: [Comment] This reverts commit bd42bf45a69b76ca3c16d7daf40633e77c0e0ace.

trinkel avatar Jun 08 '25 17:06 trinkel

Updating to only show the warning if the HEAD of the remote branch is the same as the HEAD of the local branch.

alexr00 avatar Jul 10 '25 10:07 alexr00