-
Notifications
You must be signed in to change notification settings - Fork 26.2k
build: merge-pr new checks that all requested changes have been addre… #21817
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
@@ -60,6 +61,11 @@ if [[ "$PR_CLA" != "cla: yes" ]]; then | |||
exit 1 | |||
fi | |||
|
|||
if [[ $MERGE_STATUS == *CHANGES_REQUESTED* ]]; then |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't think that this is right. or is it? we care if we have all the approvals. no? if someone objects and has the authority to do so, we should change pullapprove to not approve the PR.
the thing is that anyone can object to a change, including a non-contributor. this should not block merging.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Here is the use case.
- I approve the PR, pull approve goes green 💚 .
- You come along and object. You would expect for pull approve to go red 🔴 , but it does not. So now we are in mergeable state even touch there are outstanding reviews and that should not be it.
At this point status is green with a check mark but you have an objection. This PR makes it so that both the pull approve status as well as reviews are green. (Yes it is weird that status can be green and review red, but that is the way it is)
So we could be smarter and try to reconcile which reviews are from our team and which are not, but that would make the script complicated. The easiest is to just go to the UI and dismiss the review which you don't agree with.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
how about we use http://docs.pullapprove.com/groups/reject_value/ instead?
required: 1
reject_value: -999
that way pullapprove is always the source of truth and it's up to the reviewer/pr author to make sure that the PR is green.
// fyi: @alexeagle
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If we do that, than we can effectively discard the PR. How will dismissals be valued?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
+1 that "is this approved" should always be equal to "is pullapprove green"
Let's try this setting out and just test the scenario you're concerned about? That's what we did last time we changed the logic.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
no #21922 does not do what we want. So this still needs to be merged. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
can you please make the error message more explicit and actionable. I provided a suggestion.
scripts/github/merge-pr
Outdated
@@ -60,6 +61,11 @@ if [[ "$PR_CLA" != "cla: yes" ]]; then | |||
exit 1 | |||
fi | |||
|
|||
if [[ $MERGE_STATUS == *CHANGES_REQUESTED* ]]; then | |||
echo The PR $PR_NUMBER has requested changes from a reviewer. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
"the PR XXX has not been approved by all reviewers. Ask PR owner to obtain reviews or dismiss reviews and document the dismissal reason."
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍
…en addressed (angular#21817)" This reverts commit 4a4d749.
…en addressed (angular#21817)" This reverts commit 4a4d749.
… have been addressed (angular#21817)"" This reverts commit 5b8eb9c.
…een addressed (angular#21817)" This reverts commit 4a4d749.
…en addressed (angular#21817)" This reverts commit 4a4d749.
… have been addressed (angular#21817)"" This reverts commit 5b8eb9c.
…een addressed (angular#21817)" This reverts commit 4a4d749.
…en addressed (angular#21817)" This reverts commit 4a4d749.
… have been addressed (angular#21817)"" This reverts commit 5b8eb9c.
…een addressed (angular#21817)" This reverts commit 4a4d749.
This issue has been automatically locked due to inactivity. Read more about our automatic conversation locking policy. This action has been performed automatically by a bot. |
No description provided.