Repository navigation
review-prs: submit a blocking verdict as REQUEST_CHANGES - #169
Merged
Merged
Conversation
A review headed "request changes" was posted as a COMMENT review, which GitHub treats as informational and which does not block a merge. With a verdict profile, a review with an earlier comment still open or a finding above nit severity now uses REQUEST_CHANGES. A review with only nits stays COMMENT and says so. A PR the bot opened keeps COMMENT, since GitHub rejects a request for changes from its author.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
A review headed "Recommendation: request changes" was submitted as a
COMMENTreview. GitHub defines that as informational, so the PR shows no requested changes and nothing blocks the merge. A reviewer pointed this out on a bravebot PR.Change
For a project whose profile sets
review.verdict,post-review.pynow picks the review event:REQUEST_CHANGESlow)COMMENTAPPROVE(unchanged)A PR the bot opened itself always gets
COMMENT: GitHub rejects a request for changes from the PR's author. A profile withoutverdictis unchanged.The bot's later
APPROVEreplaces its earlierREQUEST_CHANGES, andcheck-can-approve.pyonly countsCOMMENTEDbodies, so a prior request for changes does not block a later approval.Resolving a thread once the fix is verified, and saying why one stays open, was already added in #167.
Test plan
tests/test_review_prs.py: new cases for blocking, medium, nits-only, the bot's own PR, and a profile with no verdict.pytest tests/test_review_prs.pypasses (116).make checkwas not run.