Skip to content

Propose refine-demote-round-trip-mechanics and align-status-reader-to-real-lines; record two rulings - #218

Merged
brettheap merged 3 commits into
mainfrom
change/propose-demote-fixes
Aug 19, 2026
Merged

brettheap merged 3 commits into
mainfrom
change/propose-demote-fixes

Conversation

@brettheap

Copy link
Copy Markdown
Contributor

Three commits realizing Brett's four same-day rulings (in-session multiple choice, all recommended options adopted). Both proposals are Status: draft with no Ratified: line — ratification is the change owner's.

Commit 1 — the ruling record

The README archived row for align-demote-to-round-trip-rule now shows both open rulings as RULED: Decision 3 (enrich Status at demote with task progress) rides Proposal A; Decision 1 (the shallowest-markdown selection arm) is deferred by explicit ruling until a real topic hits it — 0 of 31 staged topics reach the fallback arm today. The archive itself is untouched: its §7.2 stays the honest statement of what was open at archive time.

Commit 2 — Proposal A: refine-demote-round-trip-mechanics

One change, four parts, all in the round-trip's mechanics (the rule itself is settled and promoted):

  1. Origin resolution precedence — explicit --staging-topic, then the change's own .openspec.yaml origin block (which the forward transition writes and nothing reads), then the pick edge. Measured: 12 of 12 active changes report origin_staging_id: None today because the generator reads only pick edges the transition deletes; the fix honestly helps the 4 that declare a staged origin — the eight ad_hoc changes genuinely have no topic to return to.
  2. The demote's own INDEX.md carries a Status: header, so a returned topic's next forward transition isn't blocked by the demote's own artifact (driven SupportError cited).
  3. Proposed by: dedupe — owned by the forward transition, not the demote. Deduping inside the demote's refresh would break the promoted byte-boundedness guarantee ("leaving every other byte of that file unchanged") that makes the refresh safe over live human work; the line is written by proposal-support.py, so it's updated there. One ADDED requirement on document-lifecycle.
  4. Status at demote enrichment (Ruling, Decision 3) — active — 9 of 22 tasks done from the snapshot's own task_progress. Requires a MODIFIED delta on the promoted requirement, with the reasoning stated: the promoted text is a closed five-value list, the enrichment adds a second fact no reader could predict, and it creates a new unavailability case (a change with no tasks.md) the promoted "never fabricated" sentence must answer.

Commit 3 — Proposal B: align-status-reader-to-real-lines

The read-side half of the divergence the demote work closed on the write side. corpus.parse_status/parse_kind still count pseudo-lines (str.splitlines), so doc-health can report "missing status header" about a document that plainly has one — a false finding, worse for trust than a crash. The fix: one shared line primitive in scripts/doc_health/lines.py (dependency direction measured: ideation_dashboard → doc_health at module level, back-references only lazy), with round_trip.py importing it — reducing the Python side from two line-splitting implementations to one. Measured baseline: zero of 1079 governed files carry an exotic separator, so the change moves zero findings — which is exactly why it owns its own change and its own baseline diff rather than riding Proposal A.

Validation

  • Both changes --strict: valid. --all --strict: 63 passed, 0 failed.
  • doc-health full run: 0 new regressions, 0 findings naming either change.
  • Both listed in README's "OpenSpec Records" active block.

🤖 Generated with Claude Code

brettheap and others added 3 commits August 19, 2026 14:49
…le left open

Both open rulings from the archived change's §7.2 are decided (Brett, 2026-08-19,
in-session multiple choice, all recommended options adopted), so the README row
stops saying they are open.

Decision 3 — `Status at demote` IS enriched with the change's task progress
alongside the status, rather than carrying a value that can only ever read
`active` under `plan_demotion`'s own precondition. It rides
`refine-demote-round-trip-mechanics`, proposed alongside this, which also carries
the three defects the realization surfaced by driving both gates.

Decision 1 — the shallowest-markdown arm of the primary-fragment selection rule
stays OUT of path-only scope BY RULING, deferred until a real topic actually hits
it. The distinction matters and the row now carries it: "ruled out of scope for
now" and "nobody has looked at it" are different states, and only the first one
tells a later reader they need not re-derive the question.

The read-side half — `corpus.parse_status`'s matching pseudo-line blindness — goes
to its own change, `align-status-reader-to-real-lines`, per the same ruling that it
should own the shared reader's baseline separately rather than ride a demote fix.

THE ARCHIVE ITSELF IS NOT TOUCHED (`git diff HEAD -- openspec/changes/archive/` is
empty). An archived change is a record of what was decided when it was decided; the
rulings came after, so they belong where a reader meets the change now, which is
the README row. The archived §7.2 stays as the honest statement that those two
items were open at archive time.

Co-Authored-By: Claude Opus <[email protected]>
…Ruling 3

`align-demote-to-round-trip-rule` stopped the demote verb inverting the round-trip
rule. Driving BOTH gates afterwards — the real forward transition, then the real
demote — turned up three more defects that only a full lap can show, and Brett's
Decision 3 adds a fourth item to the same surface. None of them is the rule this
time; all four are the mechanics around it.

NAME. `refine-` on the precedent of `refine-promotion-provenance`, which is the
corpus's one prior change for "a promoted capability leaves operational questions
open and an executing session would have to invent answers". Censused all 92 change
ids first: 65 `add-`, 5 `adopt-`, 3 `align-`, then singletons. `align-` was
deliberately NOT reused — the archived `align-demote-to-round-trip-rule` aligned the
mechanism to the RULE, and a second `align-demote-*` would invite exactly the
confusion between them that the two names should prevent. This one refines the
mechanics that one left rough.

THE FOUR PARTS, and the measurement behind the first:

Origin resolution is broken for every active change, not for some. `plan_demotion`
refuses without an origin topic, and `generator.py` derives `origin_staging_id`
exclusively from possibles pick edges — which the forward transition destroys along
with the staging folder they point at. Measured rather than inferred: 12 of 12
active changes report `None`, and the corpus holds exactly ONE pick edge, carrying
no `change_id`, so the mapping the generator builds is EMPTY. (My earlier note said
six; the archive review corrected it to 12 of 12 total, and I re-measured to confirm
before citing it.) The answer is already on disk and unread — the transition writes
an origin block into `.openspec.yaml`, and `generator.py` already parses that file
via `_load_openspec_meta`, which serves `_ratifier_of` alone while the `origin` key
is read by nothing. Resolution gains a precedence order and the proposal states its
real reach: 4 of 12, because the other eight declare `ad_hoc` or nothing and have no
topic to return to, where asking is the correct behaviour rather than a gap.

The demote's own `openspec/INDEX.md` carries no `Status:` header, so a whole-folder
forward transition of a returned topic refuses with the driven
`SupportError: governed Markdown lacks Status header` — the demote leaving a landmine
for the next lap of the cycle it is half of.

`Proposed by:` accumulates one line per lap.

And Ruling 3 enriches `Status at demote`, which can only ever read `active` under
`plan_demotion`'s own precondition, with the task progress already sitting in the
snapshot.

TWO DECISIONS THE BRIEF'S FRAMING GOT WRONG, both stated in the proposal rather than
quietly worked around.

RULING 3 NEEDS A MODIFIED DELTA. I read the promoted text before deciding. It
enumerates five values in a closed em-dash list, one named "the change's status at
demote". A slot reading `active — 9 of 22 tasks done` carries a SECOND fact that no
reader of the promoted text could predict from it, and the enrichment creates a new
unavailability case the promoted sentence has to answer, since a change with no
`tasks.md` has no progress and the requirement's own "MUST NOT be fabricated" rule
needs to say what the slot reads then. Both are contract questions. The looser
reading — that "status at demote" absorbs progress — was considered and declined,
because it would make the promoted list mean whatever a later implementation put in
the slot. So: MODIFIED, restating the whole requirement per the corpus's delta
convention.

PART 3'S OWNER IS THE FORWARD TRANSITION, NOT THE DEMOTE, and this matters more than
it looks. The brief scoped the change to "the demote verb's surface (gate_console.py
+ generator.py + tests)", and the obvious place to dedupe `Proposed by:` is the
demote's refresh, since that is what runs when the line comes back. But the promoted
requirement pins that refresh as "bounded to the provenance slots and the marked
proposal-element sections, leaving every other byte of that file unchanged" — and
that boundedness is precisely what makes it safe to run over a fragment a human has
been working in. Deduping a header there would trade a data-loss guarantee for
tidiness. The line is written by `proposal-support.py`'s `proposed_content`, so that
is where it is fixed, and the code surface says so. That also gives the change a
second capability: one ADDED requirement on `document-lifecycle` for the gate that
writes the line, alongside one MODIFIED and two ADDED on `ideation-dashboard`.

Decision 1 is recorded as OUT OF SCOPE BY RULING in both the proposal's Impact and
tasks §8, so a completeness sweep meets a ruling rather than a gap — 0 of the 31
staged topics reach the shallowest-markdown fallback arm today.

`openspec validate refine-demote-round-trip-mechanics --strict` exit 0. README's
active block gains its row.

Co-Authored-By: Claude Opus <[email protected]>
… divergence

`align-demote-to-round-trip-rule` closed half of a read/write divergence and its own
review recorded the rest as open. Brett ruled the remainder into its own change so
doc-health's shared reader presents its own baseline diff rather than having it mixed
into a demote fix's. This is that change.

NAME. `align-X-to-Y` on the corpus's three `align-` precedents, and it names both
sides — the writer already counts real lines, and the reader is what must be aligned
to it. Distinct enough from the archived `align-demote-to-round-trip-rule` that the
two cannot be confused: different X, different Y.

WHAT IS WRONG. `_flip_status` — the writer that stamps a lifecycle status when a
demote returns a document — used `str.splitlines(keepends=True)`, which breaks on
`\x0b`, `\x0c`, `\x1c`-`\x1e`, `\x85`, U+2028 and U+2029 as well as the three real
endings. Two damages followed and both are now closed on the write side.
`corpus.parse_status` still scans `text.splitlines()[:STATUS_SCAN_LINES]`, and so
does `parse_kind` beside it, so the divergence is asymmetric in the most confusing
direction available: the demote writes a correct `Status: staged` and the reader can
fail to see it, reporting "missing status header" about a document that plainly has
one. A FALSE FINDING costs more trust than a crash — it accuses a correct document
and leaves the operator no recourse but to disbelieve the checker.

MEASURED BASELINE, and it is the reason the change is honest about its own value:
1079 governed markdown files carry no exotic separator anywhere, and there is no file
where the pseudo-line and real-line header windows differ. This moves ZERO findings
today. The proposal says so plainly rather than dressing a hygiene fix as a corpus
cleanup — the value is that a reader and a writer over the same documents stop
disagreeing about what a line is, before something makes the disagreement visible.
It also turns the doc-health gate into the one that carries information: the run MUST
be identical, and a moved finding is a reason to stop and explain rather than a diff
to accept.

WHERE THE PRIMITIVE LIVES, decided on the measured dependency direction rather than
taste. Module-level imports run `ideation_dashboard` → `doc_health` at five call
sites (`authoring.py`, `corpus_root.py`, `generator.py` twice, `gate_console.py`);
`doc_health` reaches back only LAZILY, inside two functions each marked
`# lazy: house guard`. So the primitive goes in `doc_health` — a new
`scripts/doc_health/lines.py` — and `ideation_dashboard.round_trip` imports it.
Putting it in `ideation_dashboard` and having `corpus.py` import it at module level
would invert the only clean direction, put the checker layer downstream of the
dashboard runtime for a text helper, and promote those two lazy back-references from
incidental to load-bearing.

A dedicated `lines.py` rather than folding it into `corpus.py`: neither the reader nor
the writer owns the definition of a line, and this corpus has already paid for one
three-implementation scanning hazard. A named home is how a fourth implementation gets
prevented instead of discovered.

OWNING SPEC. `doc-health`, one ADDED requirement — the scan rule is currently
unspecified, so there is nothing to MODIFY. `document-lifecycle` was considered and
declined: it defines the `Status:` header contract, the taxonomy and the obligation to
carry one, but not how a reader locates it, and the scanning rule is the deterministic
pass's own behaviour.

Two things the tasks make explicit because a half-fix here would repeat the very
mistake being corrected: `parse_kind` is fixed alongside `parse_status` rather than
after it, and there is a sweep task for any further `splitlines()[:` reader with an
obligation to RECORD what the sweep found, so the next reader knows it happened. The
JavaScript side stays a separate implementation — `outline-model.js` cannot import
Python — so the corpus keeps two rather than one, and the existing three-way agreement
test is what holds them; this change reduces what that test must hold from three to
two.

Validation: `openspec validate align-status-reader-to-real-lines --strict` exit 0;
`--all --strict` 63/63 exit 0 with both new changes listed; doc-health single-repo
exit 0, findings unchanged at 3/7/61/4 with 0 new regressions and no finding naming
either new change. Both README rows landed with their proposals; both are
`Status: draft` with no `Ratified:` line — Brett reads first.

Co-Authored-By: Claude Opus <[email protected]>
Copilot AI lite review requested due to automatic review settings August 19, 2026 18:58

@sourcery-ai sourcery-ai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi @brettheap! 👋

Your private repo does not have access to Sourcery.

Please upgrade to continue using Sourcery ✨

@brettheap
brettheap merged commit 071bd09 into main Aug 19, 2026
1 check passed
brettheap pushed a commit that referenced this pull request Aug 19, 2026
…real-lines

Brett's ruling, in-session 2026-08-19, verbatim: "merge and ratify both",
after reading both drafted proposals on PR #218. Both Status headers flip to
ratified with the ruling recorded, and both proposals gain the
APPROVED-BUT-NOT-YET-REALIZED banner the corpus now carries at this stage:
each has a non-empty code surface and none of it is built, so under
release-realization both stay active as approved intent until their code
merges with green realization evidence.

openspec validate --strict passes for both changes and for --all (63/63).

Co-Authored-By: Claude Fable 5 <[email protected]>

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR adds two new OpenSpec change proposals (refine-demote-round-trip-mechanics and align-status-reader-to-real-lines) and updates the root README to record their addition and the associated rulings, aligning the OpenSpec record set with the current round-trip mechanics investigation.

Changes:

  • Add proposal/design/spec/task documents for refine-demote-round-trip-mechanics (origin resolution precedence, INDEX status header landmine, Proposed-by dedupe ownership, and “status at demote” enrichment).
  • Add proposal/spec/task documents for align-status-reader-to-real-lines (reader-side “real line” scanning contract for lifecycle headers).
  • Update README.md to list both changes as Active and to record the two rulings as RULED in the archived change’s summary.

Reviewed changes

Copilot reviewed 11 out of 11 changed files in this pull request and generated 2 comments.

Show a summary per file
File Description
README.md Adds both proposals to the Active changes list and records the two rulings as RULED in the archived section.
openspec/changes/refine-demote-round-trip-mechanics/tasks.md Task breakdown and validation/gate checklist for Proposal A.
openspec/changes/refine-demote-round-trip-mechanics/specs/ideation-dashboard/spec.md Adds/updates requirements around demote refresh behavior, origin resolution precedence, and demote-written artifact validity.
openspec/changes/refine-demote-round-trip-mechanics/specs/document-lifecycle/spec.md Adds requirement for updating (not duplicating) the Proposed by: record on promotion.
openspec/changes/refine-demote-round-trip-mechanics/proposal.md Proposal A narrative, scope, and rationale for contract deltas.
openspec/changes/refine-demote-round-trip-mechanics/design.md Design decisions and rejected alternatives for Proposal A.
openspec/changes/refine-demote-round-trip-mechanics/.openspec.yaml Change metadata and origin record for Proposal A.
openspec/changes/align-status-reader-to-real-lines/tasks.md Task breakdown and validation/gate checklist for Proposal B.
openspec/changes/align-status-reader-to-real-lines/specs/doc-health/spec.md Adds requirement specifying real-line scanning for lifecycle headers in deterministic pass.
openspec/changes/align-status-reader-to-real-lines/proposal.md Proposal B narrative and rationale for consolidating the line primitive for reader/writer agreement.
openspec/changes/align-status-reader-to-real-lines/.openspec.yaml Change metadata and origin record for Proposal B.

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Comment thread README.md
line per lap, and the fix lands on the FORWARD transition that writes it, NOT the
demote's refresh: deduping there would widen the boundary the promoted
requirement pins as "leaving every other byte of that file unchanged", trading a
data-loss guarantee for tidiness. (4) Ruling 3: `Status at demote` carries task
Comment on lines +76 to +88
- `ideation-dashboard`: the promoted demote requirement's provenance sentence, for
Ruling 4 — see the delta decision below.

### New Requirements

- `ideation-dashboard`: origin resolution precedence, and the demote's own
artifacts not blocking the next transition.
- `document-lifecycle`: the forward transition's `Proposed by:` line is updated
rather than duplicated.

## Impact

**RULING 4 NEEDS A MODIFIED DELTA, and this is the reasoning.** The promoted
@brettheap
brettheap deleted the change/propose-demote-fixes branch August 21, 2026 23:57
brettheap added a commit that referenced this pull request Sep 5, 2026
…ce sets like the shipped assertion; 5.2/5.3 ticked with the observed outputs

Lane: openxfactory-2 (openXfactory-2)

This is the live test task 5.2/5.3 exist for. PR #699 (this pull request)
is the programme's first real promotion: it creates
openspec/specs/review-lane-floor-mirror/spec.md, a new tracked path under
the exactly-enumerated floor. On head 1fde704:

- merge-master-approval run 33989488802 printed the advisory lane's
  pending_floor_extension outcome for the first time ever (the parent's
  own archive record, codexFactory PR #218, could only report the report
  SHAPE with nothing pending): stage pending_floor_extension,
  covered-pending 1 (tolerance 3, pin measured), PENDING
  (created_by_candidate): openspec/specs/review-lane-floor-mirror/spec.md,
  floor evaluated 0 never-clearable path(s) touched.
- pytest-suite run 33989489654 held the required lane's own shipped
  assertion, TheRealFiles::test_every_tracked_openspec_spec_path_is_on_the_
  floor, GREEN with the same path covered-pending — but the SAME run found
  two negative controls red: NegativeControls::test_the_unmutated_surface_
  is_a_positive_first and NegativeControls::test_a_fabricated_off_floor_
  spec_path_is_refused (2 failed, 9631 passed, 21 skipped).

Cause: both controls called graced_uncovered(self.surface, self.entries,
(), ()) with hard-coded EMPTY grace sets, while the shipped assertion
beside them measures created/window from resolve_base_branch(),
created_since_merge_base() and pin_window(). On a branch that legitimately
creates a spec path, the controls saw it as uncovered where the shipped
assertion correctly saw it covered-pending. This is a defect in the
companion realization (PR #686, authoring decision E: the controls were
moved onto the graced expression but not onto the graced measurement),
predicted by Copilot review (thread PRRT_kwDOTAvnrs6fmnH4) and caught here
by the first real promotion — exactly what this live test was for.

Fix, in tests/review_lane_pin/test_floor_snapshot.py only:
NegativeControls.setUpClass now derives generated_at/created/window the
same way TheRealFiles.setUpClass and the shipped assertion do.
test_the_unmutated_surface_is_a_positive_first now asserts missing == ()
and that every covered-pending path carries a measured reason, instead of
asserting ((), ()) against a live surface that legitimately has a pending
path. test_a_fabricated_off_floor_spec_path_is_refused now takes a
baseline before adding the fabrication and asserts the fabricated path
alone is refused while pending is unchanged from that baseline.

Re-run after the fix: tests/review_lane_pin -q -> 73 passed / 2 skipped
(both controls pass on this branch); with PINNED_CORE_CHECKOUT at
codexFactory 67a6ffc9 -> 75 passed / 43 subtests, no skips.
tests/sequenced_after -q -> 162 passed. openspec validate --all --strict
-> 94 passed / 0 failed. validate-sequenced-after.py . --ledger-diff ->
consistent (173 rows, no row moves).

tasks.md: ticks 5.2 and 5.3 in the archived
2026-09-05-mirror-floor-addition-grace change with the verbatim run
output above. README.md: the mirror-floor-addition-grace archive entry
pointed at "tasks.md § Archive" for the observed result, but the evidence
lives in tasks.md's own 5.2/5.3 items — corrected the pointer, and added
one sentence naming the negative-controls defect this live test found and
fixed, so the archive narrative does not read as a clean first pass.

Refs #675
Co-Authored-By: Claude Fable 5.1 <[email protected]>
brettheap added a commit that referenced this pull request Sep 5, 2026
…6724f0), pinned at a landed regeneration (#689) — the first promotion judged under the grace (#699)

* Archive mirror-floor-addition-grace: ratified (#676), realized (#686 f6724f0), pinned at a landed regeneration (#689) — the first promotion judged under the grace

Brett Heap's word in session on 2026-09-05, verbatim "archive the grace
packets" — one word over BOTH halves of a cross-repository pair. This is the
SECOND half, and the order is this packet's own declaration rather than a
preference: proposal.md carries sequenced_after:
[codexFactory:add-floor-addition-grace], so the parent archived first
(codexFactory PR #218, merge commit 35c08994, 2026-09-05T19:47:09Z, promoting
repository-gate-floor 5 -> 12 requirements and closing codexFactory issue #203).

AND THIS ARCHIVE IS THE PACKET'S OWN FALSIFICATION TEST. It CREATES
openspec/specs/review-lane-floor-mirror/spec.md, a new tracked path under a
floor that is an EXACT ENUMERATION. Under the regime this packet replaced, that
path would be reported UNCOVERED in two lanes at once and the REQUIRED
pytest-suite would refuse this pull request until a two-repository hand repair
had run — the cost measured at five payments in two days. Under the grace now in
force in both lanes, THIS pull request's own diff creates the path, so the
required lane should stay GREEN with the path covered-pending
(created_by_candidate) and the advisory lane should print
pending_floor_extension naming it. Tasks 5.2 and 5.3 are observations of THIS
pull request's checks and are ticked in a later commit here, with run ids and
the verbatim lines, or not at all.

EVERY SHA RE-READ FROM THE GITHUB API FOR THIS ACT, not remembered. RATIFIED
2026-09-05 "ratify the companion when green, then realize it", applied at head
ce9a81e; record review/ratification-2026-09-05.md, archived with the packet;
decisions A-F stand as recommended, none separately ruled. PROPOSED by PR #676
(568fa37). REALIZED by PR #686 (f6724f0, 2026-09-05T17:30:54Z). REGENERATED AT
A LANDED COMMIT by codexFactory PR #212 (67a6ffc9, generated_at 3afd8a8 ->
f6724f0, 59 entries unchanged) — the first floor repair in this programme that
did NOT block the pull request that caused it. RE-PINNED onto it by PR #689
(b680499), five sites in lockstep, which is what makes the live test
measurable: f6724f0 IS an ancestor of this repository's main (checked with
git merge-base --is-ancestor on this tree), where the retired 3afd8a8 was not,
so B1's pin window resolves rather than fail-safing to None. No contract bundle,
no digest set, no contract_bundle_version spent, no release tag owed.

THE ESCAPE IS DISCLOSED. python3 scripts/proposal-support.py . archive
mirror-floor-addition-grace was run FIRST and REFUSED — exit 1, "change has
incomplete tasks", working tree untouched; its gate is
scripts/proposal-support.py:1079-1081, read off those three lines in this tree
and UNCONDITIONAL on WHICH box. OPENSPEC_TELEMETRY=0 openspec archive
mirror-floor-addition-grace --yes was used instead: "Task status: 26/29 tasks",
"Warning: 3 incomplete task(s) found. Continuing due to --yes flag.",
"review-lane-floor-mirror: create", "+ 7 added", "Totals: + 7, ~ 0, - 0, -> 0".
Precedents: govern-sibling-added-modified-deltas (#571 3bcde7e),
declare-spent-bundle-state (#611 7af2725), add-subject-establishment (#647
e4ff4fb), add-chain-anchoring (#669 66d11a2),
amend-chain-anchoring-readiness-and-durability (#670 3d7b8f3), and one hour
earlier this packet's own parent (codexFactory #218, 35c08994).

THREE BOXES STAY OPEN, none of them undone realization. 5.2 and 5.3 are this
pull request's own observations (above). 6.3 says in its own first words that it
is NOT OWED HERE: the D-3 escalation-tolerance NUMBER is codexFactory's to set
in its own CODEOWNERS-routed document — it stands PROPOSED at 3, offered for
veto, no veto exercised, UNRULED — and option (b) of codexFactory issue #203
remains unruled and undesigned. An openxFactory archive cannot close a
codexFactory owner's box and none is attempted.

BYTE-CHECKED PROMOTION, one way because the capability is NEW: the archived
delta's requirement region (16 744 bytes) against the created specification's
(16 745), extracted from the first "### Requirement:" line on both sides — diff
reports exactly one difference, 182a183, a single appended blank line at
end-of-file, the same one-byte archiver signature #669 and #670 each recorded.
SEVEN requirements / 28 SCENARIOS on both sides, counted rather than added.
git status --porcelain -uall openspec/specs/ names that one file and no other.

THE ## Purpose WAS WRITTEN BY THIS ACT and is the one thing in the promoted file
the archiver did not author. Leaving the tool's "TBD - created by archiving
change ... Update Purpose after archive." would have made this the ONLY promoted
specification in the corpus still carrying it — 552a3a7 repaired all 39 others
on 2026-09-05 — so it was replaced in the promoted specification directly, which
is the only surface where such an edit lands. It carries no SHALL and lies
outside the byte-checked region.

REPOINTS, listed rather than summarized. README.md: the entry MOVED from
"Active changes" to the head of "Archived changes", relinked to the archive
path, with the word, the evidence chain, the escape, the open box and the live
test stated. tests/review_lane_pin/test_floor_snapshot.py: the packet citation
in the mirror's own header comment repointed to the archive directory and the
promoted capability named beside it (comment only; no assertion, name or watched
string moved). LEFT ALONE ON THE #669/#670 PRECEDENT: contracts/review-lane-pin.yaml's
history paragraphs and every archived record that cites the old path — records
are frozen, and contracts/ carries provenance rather than navigation.

GATES ON THIS HEAD: openspec validate --all --strict 94 passed / 0 failed;
proposal-support.py . verify ok; validate-sequenced-after.py . passed. The
per-change sweep ledger is STALE by design at this commit (row
mirror-floor-addition-grace state active -> archived, plus the three derived
totals) and is re-seeded in the NEXT commit with this pull request's real
number, never by hand.

Lane: openxfactory-2 (openXfactory-2)
Refs #675
Co-Authored-By: Claude Fable 5.1 <[email protected]>

* Seed the per-change sweep ledger row for this archive: mirror-floor-addition-grace active -> archived, moved by #699

The row is MOVED BY THE TOOL, never by hand, which is the substrate's own rule:
python3 scripts/validate-sequenced-after.py . --seed-ledger --moved-by '#699'
--moved-on 2026-09-05 — "wrote tests/sequenced_after/corpus-ledger.yaml (173
rows, 1 moved by #699)". Exactly ONE row moved and the diff is one line:

  mirror-floor-addition-grace: {state: archived, class: sole,
    declares: [codexFactory:add-floor-addition-grace], depth: 0, prose: false,
    moved_by: "#699", moved_on: "2026-09-05"}

class stays `sole`, the CROSS-REPOSITORY parent declaration is carried
unchanged, and `depth: 0` is carried unchanged too — the known oddity this
packet's own design.md § 7 recorded when it filed the corpus's first
cross-repository `sequenced_after:` (a foreign parent resolves for
well-formedness but contributes no hop to a depth this repository can measure).
It is NOT hand-corrected here.

The pull request number could not be known before the pull request existed,
which is why this is a second commit rather than part of the archive: the
archive commit deliberately left the ledger STALE and said so.

AFTER, on this head: validate-sequenced-after.py . --ledger-diff reports
"per-change sweep ledger consistent with the corpus (173 rows)" over 34 active
+ 139 archived (was 35 + 138); python3 -m pytest tests/sequenced_after -q is
162 passed, where the archive commit alone had the three expected sweep
failures (test_the_LIVE_corpus_and_the_LEDGER_agree_row_by_row,
test_the_totals_DERIVED_FROM_THE_LEDGER_equal_the_MEASURED_sweep,
test_the_live_ledger_reports_the_SAME_totals_the_sweep_MEASURES).

Lane: openxfactory-2 (openXfactory-2)
Refs #675
Co-Authored-By: Claude Fable 5.1 <[email protected]>

* The live test found the controls: negative controls measure their grace sets like the shipped assertion; 5.2/5.3 ticked with the observed outputs

Lane: openxfactory-2 (openXfactory-2)

This is the live test task 5.2/5.3 exist for. PR #699 (this pull request)
is the programme's first real promotion: it creates
openspec/specs/review-lane-floor-mirror/spec.md, a new tracked path under
the exactly-enumerated floor. On head 1fde704:

- merge-master-approval run 33989488802 printed the advisory lane's
  pending_floor_extension outcome for the first time ever (the parent's
  own archive record, codexFactory PR #218, could only report the report
  SHAPE with nothing pending): stage pending_floor_extension,
  covered-pending 1 (tolerance 3, pin measured), PENDING
  (created_by_candidate): openspec/specs/review-lane-floor-mirror/spec.md,
  floor evaluated 0 never-clearable path(s) touched.
- pytest-suite run 33989489654 held the required lane's own shipped
  assertion, TheRealFiles::test_every_tracked_openspec_spec_path_is_on_the_
  floor, GREEN with the same path covered-pending — but the SAME run found
  two negative controls red: NegativeControls::test_the_unmutated_surface_
  is_a_positive_first and NegativeControls::test_a_fabricated_off_floor_
  spec_path_is_refused (2 failed, 9631 passed, 21 skipped).

Cause: both controls called graced_uncovered(self.surface, self.entries,
(), ()) with hard-coded EMPTY grace sets, while the shipped assertion
beside them measures created/window from resolve_base_branch(),
created_since_merge_base() and pin_window(). On a branch that legitimately
creates a spec path, the controls saw it as uncovered where the shipped
assertion correctly saw it covered-pending. This is a defect in the
companion realization (PR #686, authoring decision E: the controls were
moved onto the graced expression but not onto the graced measurement),
predicted by Copilot review (thread PRRT_kwDOTAvnrs6fmnH4) and caught here
by the first real promotion — exactly what this live test was for.

Fix, in tests/review_lane_pin/test_floor_snapshot.py only:
NegativeControls.setUpClass now derives generated_at/created/window the
same way TheRealFiles.setUpClass and the shipped assertion do.
test_the_unmutated_surface_is_a_positive_first now asserts missing == ()
and that every covered-pending path carries a measured reason, instead of
asserting ((), ()) against a live surface that legitimately has a pending
path. test_a_fabricated_off_floor_spec_path_is_refused now takes a
baseline before adding the fabrication and asserts the fabricated path
alone is refused while pending is unchanged from that baseline.

Re-run after the fix: tests/review_lane_pin -q -> 73 passed / 2 skipped
(both controls pass on this branch); with PINNED_CORE_CHECKOUT at
codexFactory 67a6ffc9 -> 75 passed / 43 subtests, no skips.
tests/sequenced_after -q -> 162 passed. openspec validate --all --strict
-> 94 passed / 0 failed. validate-sequenced-after.py . --ledger-diff ->
consistent (173 rows, no row moves).

tasks.md: ticks 5.2 and 5.3 in the archived
2026-09-05-mirror-floor-addition-grace change with the verbatim run
output above. README.md: the mirror-floor-addition-grace archive entry
pointed at "tasks.md § Archive" for the observed result, but the evidence
lives in tasks.md's own 5.2/5.3 items — corrected the pointer, and added
one sentence naming the negative-controls defect this live test found and
fixed, so the archive narrative does not read as a clean first pass.

Refs #675
Co-Authored-By: Claude Fable 5.1 <[email protected]>

---------

Co-authored-by: Claude Fable 5.1 <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants