Hacker News new | ask | show | jobs
by sidlls 1570 days ago
"IMO this is a very wrong way to look at pairing. It's not about one person being incapable of delivering a solution on their own, it's that having multiple perspectives on the code will lead to a higher quality and more well designed product."

That's what PRs are for. One can't use the same argument to oppose PRs, as you suggest, because of this key difference: in a PR, the person doing the review has (or ought to have) context on the broader picture (e.g. overall architecture, structure of the code in which the change is being made, etc.), but not the specific changes. It's analogous to having a proof reader: one doesn't invite a peer author to review his writings, because the peer has an implicit bias and can easily miss defects.

"Also, at least in my experience, design isn't primarily or even mostly confined to an initial design phase. Most of the 'design' of a problem occurs when you're actually coding."

This is common, unfortunately, and one of the primary reasons software is so buggy and overly complex. The code isn't the design, or shouldn't be. To draw an analogy to physical/industrial processes, the code is the machinery on the factory floor doing the work--the design is what was used as a blueprint to construct that machinery.

1 comments

As the design evolves, this stuff should really be communicated to the rest of the team before the PR. The purpose of PRs should be almost entirely about finding bugs and typos.
It should be, but another thing in this industry is the completely subjective design ideas everyone brings. So PRs inevitably have comments about the approach to abstractions, testing, etc. that are really little more than ego-stroking.
What are "draft PRs" for then?
If you mean what I think you mean, those are one of the few exceptions. I assume you mean just implementing the feature/bugfix quickly because it helps with the design discussion. Even in that case, I think it's a good idea to have a final non-draft PR (or just have people look at it again with fresh eyes once out of the draft stage) where the main goal is just to verify correctness.