Dev Process: Formalizing how PR flow & PR State #8470
Replies: 3 comments
-
For "Who can review", I think it has to be someone with commit privileges if the PR author doesn't have commit privilege. Having a someone without commit privilege reviewing code for someone else who doesn't have commit privilege seems like it might be a waste of time since neither of them can approve it and commit it. I'm not sure if it is needed to paste the commit hash in the comment. I think the commit should be pushed before your comment and then in your comment, reference that you made a change. Github will show it in time order so you can see the commit that happened before the comment. Now, if you push multiple commits for different concerns, referencing the commit hash would be useful. |
Beta Was this translation helpful? Give feedback.
-
Let's take this one topic at a time. Who can reviewWe at one point had writtenas a guideline that reviewing a good chunk of code was a prerequisite for gaining write permission. There are a lot of examples of reviews coming from people that cannot commit. I certainly reviewed quite a bit of PRs before gaining write permission myself. I think if we consider the objective and goals of CR (code review) it'll be pretty clear it's not a waste of time.
So to sum up, the benefits of reviewing when you do not have write permissions:
|
Beta Was this translation helpful? Give feedback.
-
Summary - I don't think this discussion was conclusive. With some time and reflection on CR processes, I do believe we should probably make them lighter/easier to finish. Open source and allowing a PR from anyone in the world, sometimes without any prior discussion, does make this a tricky subject. Overall I would like there to be less CR'ing and more merging (possibly directly) to trunk. |
Beta Was this translation helpful? Give feedback.
-
I think it might be beneficial to take a swing at formalizing the PR process and refining how we do PRs. The desired outcome of this discussion is that we'll have thought through the process more, shared ideas, and will have content that can then go onto the 'contributing.md' document (or similar) to specify how we handle PRs in this project.
With that:
Who can review
IMO anyone
How to respond to review comments - case: code changed - reply with SHA
I think if there are any code changes in response to a comment, the code change commit should be posted as a response. This makes it very easy to see which changes address which comments and that the comment was addressed. The reviewer can then review the diff of the commit and then either add follow-up comments or mark that thread as resolved.
This also helps notify the reviewer of changes. Pushing commits to a PR does not send notifications, but comments on a PR does. Ergo, this will be sufficient to notify a reviewer to have another look.
Using labels to indicate review status
I think we could benefit from at least two labels:
review started: this means a review is in-progress, perhaps some comments have been left, but the reviewer is still reviewing the full diff and more comments may land. Ideally we can have reviewers complete reviews in just one session, but that is not always the case. This label would help us know that the reviewer is still working on the PR and that more comments might land.
first review done: this means a reviewer has done a first full pass on the initial diff and any further review work will be done in response to new changes.
If a first-review pass is done, and there is no follow up needed, and the PR is approved and merged, then we don't need to bother labelling. A 'first review done' label therefore implies that there are questions or points of clarification needed from the author.
PR state (?) - assignments and how to "pass the ball"
A point I don't think that works very well is assigning between author and reviewer. I wonder if labels could be a good way to do this? I wonder as well if we simply reply to comments with commit SHA's, if that would be enough.
Perhaps if an author has replied to everything, that will give a notification to the reviewer who can then know they should look at the PR again. If an author has only done a partial response, and is still working on the PR, then in that case they can give a quick comment like "I responded to a couple of the comments, and am still working on the others".
In essence, maybe the way to pass the ball is simply by adding a comment of any type.
Anthing else?
This is an open discussion, please bring up any observed pain points or ideas for further improvement. Happy to discuss the above and would like feedback on those suggestions!
Beta Was this translation helpful? Give feedback.
All reactions