RFR: 1071: auto-set `/csr` flag from JBS state [v2]

Guoxiong Li gli at openjdk.java.net
Thu Nov 25 04:21:30 UTC 2021


On Wed, 24 Nov 2021 16:56:55 GMT, Erik Joelsson <erikj at openjdk.org> wrote:

>> Guoxiong Li has updated the pull request incrementally with three additional commits since the last revision:
>> 
>>  - Revise the logic of the command '/csr unneeded'
>>  - Fix the tests.
>>  - Revise logging.
>
> bots/csr/src/main/java/org/openjdk/skara/bots/csr/CSRBot.java line 95:
> 
>> 93:                     var resolution = csr.properties().get("resolution");
>> 94:                     if (resolution == null || resolution.isNull()) {
>> 95:                         log.info("CSR issue resolution is null for " + describe(pr) + ", not removing CSR label");
> 
> I think the log message should reflect if we are leaving the label or adding it.

I adjusted the log message to reflect these two situation.

> bots/csr/src/test/java/org/openjdk/skara/bots/csr/CSRBotTests.java line 168:
> 
>> 166:             TestBotRunner.runPeriodicItems(bot);
>> 167: 
>> 168:             // The bot should have kept the CSR label
> 
> Is this a check for if the bot added the label automatically?

yes, I revised the comment for readability.

> bots/csr/src/test/java/org/openjdk/skara/bots/csr/CSRBotTests.java line 172:
> 
>> 170: 
>> 171:             // Add CSR label
>> 172:             pr.addLabel("csr");
> 
> Adding the label here has no effect.

yes, because the bot has already added csr label automatically. I removed this step.

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

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


More information about the skara-dev mailing list