Pull request showing commits that have already been merged (via fast-forward merge) #39031
Replies: 14 comments 3 replies
-
As a workaround you can change the base branch for the PR to some other branch and then back to |
Beta Was this translation helpful? Give feedback.
-
Did anyone find a more permanent fix for this? I am experiencing old diffs all the time, it is really a hassle. |
Beta Was this translation helpful? Give feedback.
-
Same here we're experiencing the same issue |
Beta Was this translation helpful? Give feedback.
-
Seeing this lately here as well, but on github.com, not Github Enterprise. |
Beta Was this translation helpful? Give feedback.
-
Im seeing this as well on github.com. Driving me nuts. |
Beta Was this translation helpful? Give feedback.
-
I'm seeing the same behavior on github.com. It's so hard to then tell what changes are 'actually' to be reviewed and merged in the PR. I tried the switch-the-base-branch work around, but to no avail. |
Beta Was this translation helpful? Give feedback.
-
To me, this is a major bug and flaw in GitHub. The whole reason we use PRs is to understand what has changed and review them. We can't trust the most basic functionality of the product. This is ridiculous. |
Beta Was this translation helpful? Give feedback.
-
I ran into this today for the first time and thought I was taking crazy pills:
I was getting ready to pile onto this issue, HOWEVER I noticed one key thing that I usually do that I forgot to do in this case, which I will share in case anyone is dense like me. After merging my last PR, I forgot to pull |
Beta Was this translation helpful? Give feedback.
-
I'm experiencing the same issue as well. Has anyone got a solution for this? |
Beta Was this translation helpful? Give feedback.
-
Normally, in this case I delete my pull request and create it again from the same branch which then shows only my changes. |
Beta Was this translation helpful? Give feedback.
-
I not sure but for me rebasing the feature branch from main branch solves this issues. |
Beta Was this translation helpful? Give feedback.
-
I've found a solution for this. So apparently, I've been squash commits merged in from the target branch, and this creates a new commit and interestingly GH doesn't recognise that this commit is already in. So I have to rebase and force push, and just have to keep in mind not to squash commits before merging. Hope this helps. |
Beta Was this translation helpful? Give feedback.
-
I have the same problem. When I choose the 'rebase and merge' option the commit hashes change and even though I just merged dev to main, dev is behind again because of the changed commit hashes. This is so annoying and the only solution is to rebase and force push everytime?! There is a discussion on stackoverflow about this issue (https://stackoverflow.com/questions/68878506/github-rebase-merge-creates-new-commit-hashes). There are 3 options to merge.
Why is there no option for a fast-forward merge? Why always rebase even if there are no conflicts? If I need to rebase and force-push all the time why even have PRs at all? Additionally every force push triggers an additional build that I do not need, that is time consuming and takes resources. So I usually cancel the build, but this also means that I have an alleged 'failed' build for the branch. Is there really no way to solve this? |
Beta Was this translation helpful? Give feedback.
-
Hey GitHub, Any timeline for an actual resolution, making this issue go away for good? This is a constant annoyance, for a few reasons:
Please make it better, we really want to love GitHub but this issue is really making it hard for us |
Beta Was this translation helpful? Give feedback.
-
Select Topic Area
Bug
Body
Using GitHub enterprise, I have the following situation:
master
is at SHAdeadbeef
feature/branch1
is 3x commits ahead ofmaster
(fast-forward mergable intomaster
)feature/branch2
is 2x commits ahead offeature/branch1
(fast-forward mergable into bothmaster
andfeature/branch1
)I open up a couple of PRs:
feature/branch1
intomaster
(PR 1)feature/branch2
intomaster
(PR 2)Initially, PR 2 shows the commits from both
feature/branch1
&feature/branch2
- this is expected (total of 5 commits on the PR). However when I merge PR 1 (by way of fast-forward merge), the commit list in PR 2 continues to show all 5 commits (including the 3 that have already been merged).Expected behvaiour is for PR 2 to update and only show the (2x) commits that have not yet been merged into master yet. Note that if I create a brand new PR (merging
feature/branch2
intomaster
) then it only shows the 2x commits.Beta Was this translation helpful? Give feedback.
All reactions