2573: Support 2 reviewers by default for some areas of the JDK#1764
2573: Support 2 reviewers by default for some areas of the JDK#1764zhaosongzs wants to merge 6 commits intoopenjdk:masterfrom
Conversation
# Conflicts: # bots/pr/src/test/java/org/openjdk/skara/bots/pr/CheckTests.java
|
👋 Welcome back zsong! A progress list of the required criteria for merging this PR into |
|
❗ This change is not yet ready to be integrated. |
|
Will we be able to take advantage of this for |
Yes, we can configure 'rfr' as the two-reviewers label for jfx repo. |
Webrevs
|
| return comments; | ||
| } | ||
|
|
||
| var marker = ReviewersTracker.setReviewersMarker(2, "reviewers"); |
There was a problem hiding this comment.
I don't think this is correct. The common "2 reviewers" requirement in various part of the JDK is, at least as far as I understand it, equivalent to /reviewers 2, not /reviewers 2 reviewer. So the required additional reviewer does not need the project role "Reviewer". I think this call will result in requiring two reviews from role reviewer. I think it would be correct to just change "reviewers" to "authors", but I'm not 100% sure.
| var marker = ReviewersTracker.setReviewersMarker(2, "reviewers"); | |
| var marker = ReviewersTracker.setReviewersMarker(2, "authors"); |
There was a problem hiding this comment.
maybe @kevinrushforth can answer this question.
I am ok to change it to authors, at least 1 reviewer will be required, so it only affects the requirement of second reviewer's role.
There was a problem hiding this comment.
Erik is right. The expectation is that it is equivalent to /reviewers 2 which would be 1 reviewers and 1 author or higher.
There was a two-reviewers feature in Skara. We can configure two-reviewers labels in the configuration and if the PR contains one of the two-reviewers labels, when the PR is ready for integration, in the merge ready comment, skara would add a line "One or more changes in this pull request modifies files in areas of the source code that often require two reviewers. Please consider if this is the case for this pull request, and if so, await a second reviewer to approve this pull request before you integrate it." However, this feature was never used in production. It's only used in skara repo(e.g. #1761 (comment)), and I never noticed this message...
This PR is trying to make an improvement for this feature, when the PR contains two-reviewers label, the bot will automatically increase reviewers count to 2. Even when the label is removed later, the count won't be lowered back.
Also, the explicit "/reviewers" command will always win in this case.
sh gradlew teston macOS or LinuxProgress
Issue
Reviewing
Using
gitCheckout this PR locally:
$ git fetch https://git.openjdk.org/skara.git pull/1764/head:pull/1764$ git checkout pull/1764Update a local copy of the PR:
$ git checkout pull/1764$ git pull https://git.openjdk.org/skara.git pull/1764/headUsing Skara CLI tools
Checkout this PR locally:
$ git pr checkout 1764View PR using the GUI difftool:
$ git pr show -t 1764Using diff file
Download this PR as a diff file:
https://git.openjdk.org/skara/pull/1764.diff
Using Webrev
Link to Webrev Comment