critical: a try build can trigger a merge to master
It appears that sometimes, the result of a try build can trigger a merge to master. This seems to occur when the PR is approved between when the try build is started and when the Homu gets notified that the try build finished.
See: https://github.com/rust-lang/rust/pull/61763#issuecomment-501305359
Potential steps to reproduce (haven't tried this yet, but it fits with what happened on the referenced issue comment):
- Start a try build (e.g.
@botname try) - Approve the build (e.g.
@botname r+) - Wait until the try build succeeds
Sounds like #3 in the other direction. Perhaps disallow r+ when state is pending && try?
I think this is what caused the buggy toolchain yesterday? Cc https://github.com/rust-lang/rust/issues/113713
Sounds like the dual issue to https://github.com/rust-lang/homu/issues/214.