Misleading reason, why merging a PR is blocked #13655
Labels
topic/ui
Change the appearance of the Gitea UI
type/proposal
The new feature has not been accepted yet but needs to be discussed first.
Sorry, cannot answer the following information, as I'm not hosting the Gitea instance myself. AFAIK, it doesn't play a role either.
Description
With #9592, blocking merging a pull request was enabled, if one reviewer requested changes on the code. However, with ef89e75 (regarding #10756) the checks got extended to also cover the case if one explicitly requested reviewer hasn't given any comments yet. I feel a bit confused about this in two ways.
Think of the following test case (cf. also the test repo):
The information, why merging is blocked is misleading
As far as I was able to get from your code, the reason, why a pull request merge is blocked, is determined here:
gitea/routers/repo/issue.go
Lines 1435 to 1445 in 1bb5c09
However, obviously the condition is true also, if nobody requested changes, but still one of the explicitly requested reviewers didn't answer yet. This leads to the misleading prompt, that requested changes not have been addressed, yet.
My suggestion would be to spin of
Branch#MergeBlockedByExplcitReviewRequest
fromBranch#MergeBlockedByRejectedReview
and have both conditions separated.The explicit review request override my global config
As with GitHub, I would expect, that everything is fine to be merged, as long as one reviewer has replied with approval. However, current implementation blocks the merge with no need. Despite me not finding it handy to require all requested reviews, at least it is not clear, that this is the case. Maybe a renaming of the label for review requests from "Reviewers" to "Mandatory Reviewers" would point out clearly, what it's about (cf. Screenshot).
Screenshots
The text was updated successfully, but these errors were encountered: