RFR: 1588: Bridge messages should not be sent for PRs in draft state
Zhao Song
zsong at openjdk.org
Fri Feb 10 18:14:16 UTC 2023
On Fri, 10 Feb 2023 17:57:57 GMT, Erik Joelsson <erikj at openjdk.org> wrote:
> > I'm not sure I understand it correctly. Is the problem that the notification 'I'm putting this PR in draft to work on the feedback' won't be sent until the user makes the PR out of draft mode? Maybe it's not a big problem, the window is not very big, just few minutes.
>
> Yes, the problem is that the last comments or events before changing a PR to draft could be delayed until the PR is taken out of draft. The size of the window for this to happen is usually just a few minutes, but depending on the state of the bots, it could be much longer. My example scenario seems like a very plausible series of events however, a user comments about making it draft and then puts it in draft, more or less at the same time. In that case it's very likely that the last comment hits the window. Also delaying that particular message would be very confusing to users, and I can guarantee that if it happened, we would get a lot of complaints. A PR could be moved to draft for weeks, and suddenly receiving week old comments from before it was put in draft is pretty bad.
Ok, I think the solution is that we don't filter in `MailingListBridgeBot#getPeriodicItems`. Instead, in `ArchiveWorkItem#run`, we can check if the pr is in draft mode and record the time. This recorded time can then be used to filter the comments.
-------------
PR: https://git.openjdk.org/skara/pull/1469
More information about the skara-dev
mailing list