Repository navigation
Remove wasm-bindgen-bot's merge-ready label while a review runs - #79
Conversation
There was a problem hiding this comment.
✅ This PR adds a start job to bot.yml that runs alongside analyze and removes merge-ready as soon as a review starts. That way an approval landing on a newly pushed head can't turn on auto-merge before the bot has reviewed that head. Whether to remove the label is decided by the shared context.mjs, not the workflow if, so start makes the same review/skip choice as analyze, including skipping pushes from third parties. Because the app removes the label, the resulting unlabeled event still turns off auto-merge through the existing -merge-ready path, and post checks the head SHA before it adds the label back. Looks good to merge. One small gap: the job's if doesn't fire for the legacy bot-request-review label, for bot-review on drafts, or for reviews started from a comment or from the Actions tab. None of those involve a new unreviewed commit, so the label just doesn't show that a review is running in those cases.
wasm-bindgen-bot's
merge-readylabel stayed on a PR from its last review until the review of a new push finished, so it gave no sign that a review was running, and an approval of the new head in that window would enable auto-merge on an unreviewed commit.This adds a
startjob, run alongsideanalyzewith the same decision on whether the event is reviewed, that removesmerge-readyas a review starts. The removal turns auto-merge off, andpostadds the label back when the review finds no concerns.