Repository navigation
Commit 4b0256e
README: a cross-reference to a section that was never written, and a gate for the class (#943)
Under Kernel#fork the README said:
fork { ... } *does* exist and runs the block in the same process -- see the
table under *Known divergences*, because code that forks to isolate or to
drop privileges gets neither here.
⛔ There is no "Known divergences" table. `git grep -i divergenc` over every
markdown file in the repository returns that citation and nothing else.
The sentence names the stake exactly right -- a program that forks to drop
privileges drops none here -- and then sends the reader to the one place that
would have told them what to do about it, which does not exist.
## The fix says the thing instead of promising it
The divergence is now inline, with the measurement: `x = 1; fork { x = 99 }`
leaves the parent's x at 99 where MRI 4.0.7 leaves it at 1 (measured today
through cmd/oracle), and the Integer returned is indistinguishable from a real
pid. The reason it exists -- Puppet::Util::Execution.execute is built on it --
is stated, and the open questions point at #774 and the parity plan #941.
## The gate, measured before it was written
A guard on prose is worthless if it fires on prose that is fine, so the
population came first. TestReadmeCrossReferencesResolve finds every italic
phrase introduced by "see" or "under" and requires a heading or a bold run-in
item to name it:
*Set* *Supported today* (x3) *Running Puppet* *Runtime conformance*
*Status* -- and, until this change, *Known divergences*
8 before, 7 after, and NO false positives: emphasis such as `fork { ... } *does*
exist` is not matched, because the italic has to follow "see" or "under"
immediately.
⛔ Proved by mutation, not by passing: putting the dangling reference back makes
it fail by assertion, naming *Known divergences*.
Two things the writing of it taught, both recorded in the test:
- I counted the population BY HAND first and got 4. The regexp finds 8 -- my
grep pattern only matched capitalised titles in one phrasing and silently
missed three repeats and *Status*. A population counted by eye is what this
test replaces.
- The first draft logged "all resolve" unconditionally, and printed it directly
under a failure it had just reported. A summary that contradicts its own
output is how a reader learns to stop reading summaries; it now prints the
dangling tally.
⛔ It also flattens the README before matching, because "see *Set* under
\n*Supported today*" wraps across two source lines and a line-based check sees
neither half.
Refs #774, #941
Co-authored-by: Claude Opus 5 <noreply@anthropic.com>1 parent 131942a commit 4b0256e
2 files changed
Lines changed: 114 additions & 3 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
461 | 461 | | |
462 | 462 | | |
463 | 463 | | |
464 | | - | |
465 | | - | |
466 | | - | |
| 464 | + | |
| 465 | + | |
| 466 | + | |
| 467 | + | |
| 468 | + | |
| 469 | + | |
| 470 | + | |
| 471 | + | |
| 472 | + | |
467 | 473 | | |
468 | 474 | | |
469 | 475 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
| 75 | + | |
| 76 | + | |
| 77 | + | |
| 78 | + | |
| 79 | + | |
| 80 | + | |
| 81 | + | |
| 82 | + | |
| 83 | + | |
| 84 | + | |
| 85 | + | |
| 86 | + | |
| 87 | + | |
| 88 | + | |
| 89 | + | |
| 90 | + | |
| 91 | + | |
| 92 | + | |
| 93 | + | |
| 94 | + | |
| 95 | + | |
| 96 | + | |
| 97 | + | |
| 98 | + | |
| 99 | + | |
| 100 | + | |
| 101 | + | |
| 102 | + | |
| 103 | + | |
| 104 | + | |
| 105 | + | |
0 commit comments