In SKARA-2408 and SKARA-2552, I updated the bot to do one more checkWorkItem after a pr is marked as auto labeled.
Currently, when the pr bot restarts, the bot would schedule a PullRequestCommandWorkItem for every pr(including closed prs), in the end of PullRequestCommandWorkItem, a LabelerWorkItem will be scheduled for each pr as well. In the LabelerWorkItem, when it finds the bot doesn't have label configuration, the bot will mark the pr as auto labelled and schedule a CheckWorkItem with forceUpdate. This is the issue, the bot shouldn't schedule any CheckWorkItem when the bot doesn't have label configuration. Otherwise, the bot would re-evaluate all the prs with forceUpdate.
Also, if the pr is already closed, the LabelerWorkItem shouldn't schedule any CheckWorkItem for it.
Currently, when the pr bot restarts, the bot would schedule a PullRequestCommandWorkItem for every pr(including closed prs), in the end of PullRequestCommandWorkItem, a LabelerWorkItem will be scheduled for each pr as well. In the LabelerWorkItem, when it finds the bot doesn't have label configuration, the bot will mark the pr as auto labelled and schedule a CheckWorkItem with forceUpdate. This is the issue, the bot shouldn't schedule any CheckWorkItem when the bot doesn't have label configuration. Otherwise, the bot would re-evaluate all the prs with forceUpdate.
Also, if the pr is already closed, the LabelerWorkItem shouldn't schedule any CheckWorkItem for it.
- links to
-
Commit(master) openjdk/skara/becf9411
-
Review(master) openjdk/skara/1729