RFR: 401: Allow a PR author to manually add reviewers

Jorn Vernee jvernee at openjdk.java.net
Wed May 27 15:11:23 UTC 2020


On Tue, 26 May 2020 11:43:46 GMT, Robin Westberg <rwestberg at openjdk.org> wrote:

> Hi all,
> 
> Please review this change that adds a `/reviewer` command that allows the PR author to manually add reviewers. The
> implementation is fairly similar to the `/contributor` command.
> Best regards,
> Robin

Looks good. 2 minor suggestions inline

bots/pr/src/main/java/org/openjdk/skara/bots/pr/ReviewerCommand.java line 76:

> 75:         if (bot.ignoreStaleReviews()) {
> 76:             reply.println("This project requires authenticated reviews - please ask your reviewer to flag this PR
> as reviewed."); 77:             return;

Maybe this should contain an `@<pr-author>` as well? (both to notify and make it clear who is being addressed).

bots/pr/src/main/java/org/openjdk/skara/bots/pr/ReviewerCommand.java line 98:

> 97:                                        .filter(Objects::nonNull)
> 98:                                        .collect(Collectors.toSet());
> 99:

I see this stream pipeline duplicated a few times already (in CheckablePullRequest and CheckRun). Maybe you want to
move this to a helper method somewhere?

-------------

Marked as reviewed by jvernee (Reviewer).

PR: https://git.openjdk.java.net/skara/pull/630


More information about the skara-dev mailing list