I found myself quoting Deming in a question about Pull Requests (PR’s) today.
“Inspection does not improve the quality, nor guarantee quality. Inspection is too late. The quality, good or bad, is already in the product. As Harold F. Dodge said, ‘You can not inspect quality into a product.’“
W. Edwards Deming, “Out of the Crisis”
Many people will make the argument that PR’s are a quality step and that if we got rid of them, there would be no way to ensure quality.
Except PR’s are an inspection step, and Deming is clear that by the time we’re inspecting, the quality is either already there or not. We cannot inspect quality into the product. If we want to build in quality then we need to be approaching that far earlier than the PR.
That’s not to suggest that there is no value to inspection. It can identify problems with the earlier process that led to poor quality, but is not itself going to add any quality to the product. If we’re finding problems here then it’s the process that needs to be fixed first, before we fix the product.
My preference for improving quality is increased collaboration. Ensemble work (aka mob programming) or pair programming. Anything where we get multiple people actively building the product together, rather than building a piece and asking someone else to inspect it.
Update: A number of people have pointed that that PR’s can be used for quality if the PR is for early review of something still in progress. Yes, that’s absolutely true, and yet in actual practice that’s quite rare. In the far more typical case, the PR is about completed work.