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

Erik Joelsson erikj at openjdk.org
Tue Nov 1 18:02:05 UTC 2022


On Tue, 1 Nov 2022 17:39:51 GMT, Zhao Song <zsong 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.
>
>> 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.

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

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


More information about the skara-dev mailing list