RFR: 1393: PR bot fails on missing .jcheck/conf

Zhao Song zsong at openjdk.org
Tue Nov 1 18:06:41 UTC 2022


On Tue, 1 Nov 2022 17:58:41 GMT, Erik Joelsson <erikj at openjdk.org> wrote:

>>> Maybe it would be even better to throw an exception instead of returning Optional.empty(). We can't recover from it in CheckWorkItem anyway, and with a typed exception we can communicate more exactly what went wrong, and we can catch exactly that exception type and write the message.
>> 
>> I thought about it in the very beginning and I found that  if we choose to throw an exception, we will need to surround a lot of code with try catch because the scope of `census` is big.
>
> Note that there are a lot of different `CensusInstance` implementations. They aren't shared between different bot modules. The one in `bots.pr` is only used in two locations, and the other location would probably also like a quick exit on this failure.

> 

Yes, I just mean we need to surround a lot of code with try catch in `CheckWorkItem#prRun`.  If it is ok, I will change it.

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

PR: https://git.openjdk.org/skara/pull/1407


More information about the skara-dev mailing list