In Github, are PR reviewers notified when a new commit has been made after they request changes? - github

I'm not sure if this is an appropriate question for SO but say I make a PR in Github and the reviewers of the PR request changes before it is merged. When I subsequently commit the requested changes on my branch that I am trying to merge are the reviewers notified that I have made the change? Or do I need to explicitly comment on the PR that I have made the change and tag the reviews?

When I subsequently commit the requested changes on my branch that I am trying to merge are the reviewers notified that I have made the change?
They will be able to see/notified you made a new commit, but they won't know if it addresses the PR concerns (or if you're simply adding unrelated changes). Best practice is to comment on the PR and tell them you made changes - tagging the reviewer(s) definitely won't hurt!

Since February 2019, no need to comment: you can Re-request review on a pull request
If changes have been made to a pull request that has already been reviewed, you can now re-request a review with a single click in the pull request’s sidebar. This will notify the requested reviewers that changes have been made.

Related

Azure Devops pull request update content after reject

We are working with Azure Devops, merge into main only via PR.
If the QA team reject the PR because of some bug in the code, and the developer fixed the bug - do we have to open a new PR?
Can we not update the code on the current PR and re-submit it?
Thank you.
Rejecting a PR is a vote on PR changes
It odes not prevent you to push additional commits on it, requesting for a feedback reset, and a new vote.
You can use a branch policy:
To reset votes whenever a PR author pushes new changes, select Reset code reviewer votes when there are new changes in the Require a minimum number of reviewers branch policy.

how to update the branch in an existing devops pull request?

Creating a pull request from your feature branch is easy.
Then you do some more fixes to your feature branch, and push back to origin.
The pull request is still pointing at an old version of your branch.
How do you update the feature request to the latest version of your feature branch?
We can create a new PR, but then you have to fill out all the info again, and you lost the PR review history.
IS there another way?
There is no need to update the pull request to include the follow-up commits. Once you've created a pull request, you can push commits from your topic branch to add them to your existing pull request. These commits will appear in chronological order within your pull request and the changes will be visible in the "Files changed" tab.

How to permanently delete an abandoned pull request in Azure DevOps?

We have an abandoned pull request which we would like to permanently remove. How can this be done? There doesn't seem to be a 'delete' or 'remove' option. Thanks.
How to permanently delete an abandoned pull request in Azure DevOps?
Sorry for any inconvenience.
I'm afraid there is no such way to permanently delete an abandoned pull request in Azure DevOps at this moment.
Microsoft thinks that data retention and traceability is important to a lot of our customers - it's not as simple as always providing CRUD operations for every artifact. But more and more customers are requesting delete pull requests, or at least the ability to delete abandoned pull requests.
Just like Spevacus comment, this feature is under Review, and Microsoft replied:
Your suggestion has been queued up for prioritization. Feature
suggestions are prioritized based on the value to our broader
developer community and the product roadmap. We may not be able to
pursue this one immediately, but we will continue to monitor it up to
90 days for community input
You could vote and add your comments for this feedback. When there are enough community votes and comments with reliable feedback, the product team members will take this feature request seriously.
Hope this helps.
While an abandoned pull request cannot currently be permanently deleted in Azure DevOps, it can be closed. The comment/update history will remain, but the pull request will not show up in the "Abandoned" list.
Delete the pull request's source branch if it still exists.
Create a new branch based on the main branch with the same name as the original source branch.
Reactivate the pull request
Close the pull request
The new status will be "Completed"
I also wanted to do this so that I wouldn't have an open pull request showing in open pull requests forever. So you can't delete the pull request, but at least you can get it marked as closed/completed. As a workaround until the delete feature is added you can do the following:
Create a temporary branch, let's say we call it "DeleteMe"
In your pull request, change the destination branch to DeleteMe
Complete the pull request.
In DeleteMe branch, if you want this updated with any new changes then you can make it updated to current. Otherwise just make any change to a file. You can add in a space on a comment for instance.
Create a new pull request to merge DeleteMe back into the original branch.
Complete the pull request and delete the DeleteMe branch.
Now the pull request will be closed/completed.
My priority was to prevent an inadvertent merge to Prod.
Hence you can:
add yourself as reviewer, then Reject; Save
as above, change the target branch to a dummy branch; Save
place [DELETED} at start of the title; Save
set the PR to Draft - that resets your rejected review
https://learn.microsoft.com/en-us/azure/devops/release-notes/2018/sprint-143-update#draft-pull-requests
or "Abandon" the PR

Is there a way to make Github branch wait for multiple reviews to be approved for a pull request?

Generally, a Github branch goes to "Approved" state when at least one person approves the changes. But sometimes a branch may be needed to be reviewed by more than one person and it could only be merged when everybody approves.
Is there a way to override default behavior of Github to setup a branch not to go to "Approved" state until all reviewers have approved the changes? Basically I don't want the branch to show up in green until then.
GitHub has the ability to require multiple reviewers.
GitHub does not currently support this functionality.

Approve changes in github

I have a git enterprise in my company and we have a system like this documentation for review the pull request before merging into master. But here is coming a problem. People are reviewing when the branch is still in progress.
How I can do, to remove review after a new commit was done in a branch?, or check that the review is the last thing before have the button of merge pull request green?
Thanks!
You can add a tag "work in progress" on the pull request.
https://help.github.com/articles/working-with-tags/