bors
bors copied to clipboard
Implement refresh mechanism for unknown mergeable PRs
Fixes #218
This PR:
- Adds mergeable queue processing on periodic refresh
@Kobzol could you take a quick look to make sure I'm on the right track on how I've implemented the background processing for the mergeable queue?
You can ignore the logic and what actually happens right now since it's very much a WIP, but I want to make sure I'm going about the actual queue task implementation correctly.
Yeah, I think that's mostly fine. I would use a "native" queue from tokio, rather than implementing it with a Mutex + sleep, that's unnecessary and hacky. Also waiting 10 secs for the item to be processed in tests would be annoying.
Also I would split this into multiple PRs:
- Introduce the queue and the processing loop, push to the queue after pushes to the base branch.
- Also push to the queue in the refresh handler.