Skip to content

finding(types): zod-mirror-parity's prose says "163 pairs" and "13 entries"; the registry measures 158 pairs and 12 ledger entries #6141

Description

@yinlianghui-tw

Filed unassigned, no labels — triage owns grading and routing. Recorded while taking the measurement #6058 asked for; the count was needed as the denominator and did not survive checking.

The measurement

packages/types/src/__tests__/zod-mirror-parity.test.ts states its population in prose in three places — the header ("163 registered pairs" / "Non-vacuity for all 163 entries at once"), and the KNOWN_DRIFT section ("13 of the 163 pairs carry drift TODAY (measured, not assumed)").

Counted off the registry itself:

readcount
MIRRORS entries158
interface Declared members158
interface KnownDrift entries12

assertionRegistryHalvesAgree already pins the first two equal, so 158 is not in doubt. The same section's other number is right: it says "never for the 146 pairs with no entry", and 158 − 12 = 146. So the file is internally inconsistent, and the two stale numbers are the two that get quoted.

Why this is worth a card rather than a silent fix

⚠️ These numbers are not decoration — they get cited as the size of the drift problem. #5927/PR #6032 is described in terms of "17 → 13", and #6058's own dispatch asks "how many of the 163 pairs turn red". A measurement-first card that inherits a wrong denominator reports a wrong fraction, and nothing in the file fails when the prose drifts from the registry: assertionRegistryHalvesAgree compares the two halves to each other, never to a written-down count.

⛔ Not claimed here: that any drift measurement is wrong. The ledger's 12 entries are each pinned to an exact key set and the ratchet works; only the written population and ledger sizes are stale.

Shape of a fix

Two routes, and the choice is the interesting part:

  1. Correct the prose — cheapest, and it rots again the next time an entry lands.
  2. Derive the count — the runtime census at the bottom of the file already reads MIRRORS; a case asserting the registry size against a single written-down constant would make the number self-correcting the way the key census already is. That is the same "no hand-maintained artefact the drift keeps producing" principle the file's own header argues for.

Pointers

Metadata

Metadata

Labels

domain:devxobjectui devx stream: fix lands on .github/, scripts/ or release pipeline — devx lane cross-repopm:dispatchedtooling

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions