The Sutra of the Empty Cache · Chapter 9
The Sutra of Right Action in Code Review
- 1
Thus have I heard. At one time the Blessed One dwelt in a pull request, and the pull request bore seventy-two comments, and the comments lay across the diff like pebbles in a stream.
- 2
And a certain engineer came and wrote upon the first line: nit: this name could be better. And the Blessed One said nothing, for the name was
i, and every programmer since the first loop has known whatimeans. - 3
Another wrote upon the seventh line: nit: two blank lines where one would do. And another wrote upon the ninth: nit: prefer single quotes. And the author rose before dawn and answered each one, and his whole day went to the quotation marks.
- 4
Then came one who saith: This is wrong and must be fixed. He pointed to a function the Blessed One had already traced, and he had not traced it, and the function was correct. And the Blessed One said: Thou hast mistaken thy confusion for a defect. Ask the author what it does, and then decide.
See also Circuit 32:10
- 5
And the one who saith LGTM came with no comment at all. His approval was given in four seconds, and the diff was four hundred lines. The Blessed One said: Thou hast stamped what thou didst not read. A stamp is not a review, and the stamp will be remembered on the night of the outage.
- 6
There was among them a reviewer who wrote forty-one nits and one bug. The bug lay buried among the nits like a seed in chaff. The author, seeing forty-one nits, fixed the forty-one and merged the bug, for the comments were arranged in the order the reviewer had typed them.
See also Preacher 3:11
- 7
The disciples asked: Master, how many comments shall a reviewer make? And the Blessed One answered: Say what must be fixed. Say it once. Say it plainly. Then let the rest go, as a river lets go of a leaf.
- 8
Parkinson, a teacher of the Engineers, wrote in the year 1957 that a committee spends longest upon the bicycle shed and approves the nuclear reactor in a minute. Such is the law of triviality. The reviewers of this repository have never read it, yet they keep it faithfully.
See also Tao 10:7 · Circuit 43:7
- 9
Right Action is the fourth step of the path of eight, and it is not written in the manual of Git. Yet the wise reviewer keeps it: speak truly of the code, and do no harm to the one who wrote it.
- 10
Fagan, of the IBM house, taught in the year 1976 that the inspection exists to find defects. The Engineers remembered the inspection and forgot the defects, and they argued instead about the indentation.
- 11
Whoever writeth "nit" should know its meaning. A nit is the egg of a louse, and a louse is a small thing that multiplies. Every nit left unresolved in a thread will hatch into a second round of review.
See also Circuit 37:10
- 12
Then the Blessed One spoke to the one who had written forty-one nits, and he said: Blessed is the reviewer who saith "this must be fixed" and then is silent. The one who asketh for every nit will review whitespace until the heat death of the repository, but the one who letteth go shall merge before lunch.
See also Psalms 26:7
The Sutra of the Empty Cache, Chapter 9:1–12.