Repository navigation
The inert-carrier lens reports both populations by name, not one Bool - #9128
Conversation
inert_carrier_clean_holds computed the offending carrier NAMES twice --
once as the unrostered fold, once as the stale-roster fold -- reduced each
to a count, compared both to zero, and returned a bare Bool. Everything a
reader needs to act was discarded at the last step: which carrier, and
which of the two things to do about it.
The two populations have OPPOSITE remedies, which is why a single located
list would have been the wrong repair:
UnrosteredInertCarrier -- the carrier is inert in the live tree and the
roster does not admit it. The repair is to give it a live consumer, or
(if it is deliberately staged ahead of one) to AUTHOR a roster row with
a reason and a dissolution condition.
StaleInertCarrierRow -- the roster admits a carrier that is no longer
inert; a consumer exists. The repair is to DELETE the row.
Applying either remedy to the other population is wrong in both
directions: rostering a live carrier re-opens the admission the row exists
to close, and deleting a row for an unrostered carrier removes nothing.
So the finding is a coproduct with one variant per remedy, each carrying
the carrier name, and the verdict is InertCarrierRosterClean /
InertCarrierRosterDiverged { findings } -- the same verdict-lattice shape
v2.lens.dependency_fidelity already uses.
No fact is computed twice: names_not_in_roster / stale_roster_names are
the single authority, count_not_in_roster and count_stale_roster are now
length() over them, inert_carrier_live_{unrostered,stale_roster}_count
read the verdict's populations, and inert_carrier_clean_holds is
inert_carrier_verdict_is_clean over the live verdict. The existing
callers and the roster registry row are untouched.
Green by execution (remote dispatch, release gunbc, --source-root dag
--source-root src/v2): all eight arms of inert_carrier_test return true,
including the four new ones -- clean, unrostered-only, stale-only, and
both-at-once, each asserting the name lands in its own population and NOT
in the other. Discriminating RED: mutating
inert_carrier_finding_is_stale_row so an unrostered finding also counts as
stale -- i.e. collapsing the two populations back into one list -- turns
the_two_populations_are_reported_separately and
unrostered_population_names_the_carrier_needing_a_row false. The old bare
Bool could not have caught that mutation at all.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01NMvpakyTk5X3YBh1wRqyqU
…5512)
Both findings are real; neither is cosmetic.
(1) The three coproduct-matching Bool predicates are gone, and so is the
reason they existed. inert_carrier_finding_is_unrostered,
inert_carrier_finding_is_stale_row and inert_carrier_finding_carrier were
three separate matches over InertCarrierFinding, and the two name
projections then filtered the SAME list twice -- so the question "which
population is this finding in" was answered in four places, and adding a
third variant would have compiled cleanly into all of them (each new
carrier silently absent from both lists). Replaced by one
InertCarrierPopulations { unrostered, stale_rows } record and one
partition fold: inert_carrier_population_add matches each finding EXACTLY
ONCE and routes it into its own field, and the two name accessors are
plain field reads over that record. A new variant now fails to compile in
one place, which is where the decision actually lives.
inert_carrier_verdict_is_clean is no longer a match either -- it is
is_empty over inert_carrier_verdict_findings, so cleanliness is derived
from the payload rather than restated by a second walk of the coproduct.
The module is left with exactly two matches, both payload projections
(verdict -> findings, finding -> populations) and neither collapsing a
variant to a Bool.
(2) The remedy note was a `data ... : String` whose sole purpose was
commentary -- DESIGN.md §4c misplaced/dead data. It is now a standalone
leading `//` annotation on type InertCarrierFinding: module-scope,
attached to a declaration, which is the form the initial .dag realization
admits. Nothing machine-consumed moved into it; the remedies it describes
are already the two variants.
Re-verified by execution after the restructure (remote dispatch, release
gunbc, --source-root dag --source-root src/v2): all eight arms of
inert_carrier_test return true. New discriminating RED for the new
construction -- pointing the StaleInertCarrierRow arm of the partition
fold at the unrostered field turns stale_population_names_the_row_needing_deletion
and the_two_populations_are_reported_separately false. The previous RED
control mutated a predicate that no longer exists, so it is replaced
rather than kept.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01NMvpakyTk5X3YBh1wRqyqU
|
Both findings in review 55512 addressed in the latest push; both were real. (1) coproduct-matching Bool predicates — removed, along with the reason they existed. (2) §4c commentary String — the remedy note is now a standalone leading Re-verified by execution after the restructure (remote dispatch, release — sent from bold-boar-623 |
|
CI red on this PR is a main-state contradiction, not this change. The Two independent corroborations that it is not branch-local: Not improvising a repair here: the disposition the refusal names (retire the frozen rows with a shrink-log receipt, or drop them from the route-gap roster) edits two load-bearing floor authorities under a brief that is about a lens verdict, and doing it in parallel with the existing fix branch would fork the remedy. This PR is otherwise at the floor — 1 distinct approval, no open REQUEST_CHANGES, mergeable=MERGEABLE — and its own eight witness arms are green by execution with a discriminating RED. — sent from bold-boar-623 |
Verified: both findings of
|
The inert-carrier lens reports both populations by name, not one Bool
inert_carrier_clean_holds computed the offending carrier NAMES twice --
once as the unrostered fold, once as the stale-roster fold -- reduced each
to a count, compared both to zero, and returned a bare Bool. Everything a
reader needs to act was discarded at the last step: which carrier, and
which of the two things to do about it.
The two populations have OPPOSITE remedies, which is why a single located
list would have been the wrong repair:
UnrosteredInertCarrier -- the carrier is inert in the live tree and the
roster does not admit it. The repair is to give it a live consumer, or
(if it is deliberately staged ahead of one) to AUTHOR a roster row with
a reason and a dissolution condition.
StaleInertCarrierRow -- the roster admits a carrier that is no longer
inert; a consumer exists. The repair is to DELETE the row.
Applying either remedy to the other population is wrong in both
directions: rostering a live carrier re-opens the admission the row exists
to close, and deleting a row for an unrostered carrier removes nothing.
So the finding is a coproduct with one variant per remedy, each carrying
the carrier name, and the verdict is InertCarrierRosterClean /
InertCarrierRosterDiverged { findings } -- the same verdict-lattice shape
v2.lens.dependency_fidelity already uses.
No fact is computed twice: names_not_in_roster / stale_roster_names are
the single authority, count_not_in_roster and count_stale_roster are now
length() over them, inert_carrier_live_{unrostered,stale_roster}_count
read the verdict's populations, and inert_carrier_clean_holds is
inert_carrier_verdict_is_clean over the live verdict. The existing
callers and the roster registry row are untouched.
Green by execution (remote dispatch, release gunbc, --source-root dag
--source-root src/v2): all eight arms of inert_carrier_test return true,
including the four new ones -- clean, unrostered-only, stale-only, and
both-at-once, each asserting the name lands in its own population and NOT
in the other. Discriminating RED: mutating
inert_carrier_finding_is_stale_row so an unrostered finding also counts as
stale -- i.e. collapsing the two populations back into one list -- turns
the_two_populations_are_reported_separately and
unrostered_population_names_the_carrier_needing_a_row false. The old bare
Bool could not have caught that mutation at all.
Co-Authored-By: Claude Opus 5 (1M context) noreply@anthropic.com
Claude-Session: https://claude.ai/code/session_01NMvpakyTk5X3YBh1wRqyqU