Description
Hi @lunny
After commit #36186 fafd1db1 on main, the Pull Request Commits tab may include
commits from other PRs that were merged into the target branch (main),
even though those commits are not reachable from the PR branch itself.
The PR branch history is correct (git log is clean), but the Gitea UI
incorrectly shows extra commits in Pull request → Commits.
This behavior did not occur before fafd1db1, so this appears to be a regression.
Gitea version
- Branch:
main
- First bad commit:
fafd1db1
Reproduction steps
- Create
PR1 from main (do not merge it).
- Create
PR2 from main (independent from PR1).
- Merge
PR2 into main.
- Open
PR1 and go to Pull request → Commits.
Expected behavior
The commits list of PR1 should only include commits that are reachable
from the PR1 branch and not yet merged into main.
Actual behavior
The commits list of PR1 also includes commits from PR2,
even though those commits are not present in the PR1 branch.
Verification
The PR branch history itself is correct:
git log PR1_branch --oneline
Gitea Version
main fafd1db
Can you reproduce the bug on the Gitea demo site?
Yes
Log Gist
No response
Screenshots
Git Version
No response
Operating System
No response
How are you running Gitea?
command-line
Database
PostgreSQL
Description
Hi @lunny
After commit #36186
fafd1db1onmain, the Pull Request Commits tab may includecommits from other PRs that were merged into the target branch (
main),even though those commits are not reachable from the PR branch itself.
The PR branch history is correct (
git logis clean), but the Gitea UIincorrectly shows extra commits in Pull request → Commits.
This behavior did not occur before
fafd1db1, so this appears to be a regression.Gitea version
mainfafd1db1Reproduction steps
PR1frommain(do not merge it).PR2frommain(independent from PR1).PR2intomain.PR1and go to Pull request → Commits.Expected behavior
The commits list of PR1 should only include commits that are reachable
from the PR1 branch and not yet merged into
main.Actual behavior
The commits list of PR1 also includes commits from PR2,
even though those commits are not present in the PR1 branch.
Verification
The PR branch history itself is correct:
Gitea Version
main fafd1db
Can you reproduce the bug on the Gitea demo site?
Yes
Log Gist
No response
Screenshots
Git Version
No response
Operating System
No response
How are you running Gitea?
command-line
Database
PostgreSQL