Description
First off thank you for this OS project - amazing work!!
- Gitea version (or commit ref): 1.11.0+dev-352-g66028d58f (gitea.io)
- Also on private hosted v1.10.0, and latest dev build in Docker
- Can you reproduce the bug at https://try.gitea.io:
Description
Gitea shows a false merge/PR conflict when there is none.
This issue is also present in many other scenarios that involve pushing changes to a branch being merged into which do not cause a merge conflict. I have simplified this issue by using the most trivial example to clearly illustrate the issue.
This issue is also on my locally hosted servers of which I have both v1.10.0 and the latest dev build in Docker - they all (including on try.gitea.io) exhibit the same issue.
NOTE: This is a blocking issue for using Gitea even in a trivial scenario.
Steps to reproduce:
Create repo on Server (https://try.gitea.io/)
Clone (empty) repo from Server
Add a file (README.md) with some text
Commit initial commit
Push to branch master on Server
Create branch A off of master
Add a line to file (non-conflicting - i.e. at the end)
Commit A
Push to branch A on Server
Create branch B off of A
Add line to file
Commit B
Push to branch B on Server
On Server:
Create PR for A into master
Create PR for B into master
Do PR A merge on Server
PR B now shows merge conflict as shown in screenshot
On my local instance of Gitea (v1.10.0) which has the same issue, I was able to do a git diff
of master
with B
(on the bare repo) and it correctly showed only the changes that were made on branch B
(since PR A was now merged int master
) which is not a conflict if B
was merged into master
(i.e. for PR B).
To prove that last statement, do the following additional steps:
Locally:
Checkout master
Pull master from Server (https://try.gitea.io/) - it updates no problem (i.e. master + A - merged from PR A)
Merge B into master - works 100% - no conflicts
Screenshots
What you see in PR #2 (PR B) in the example.