Repository navigation
carve manifest: a manifest-declared post-shed phase (RULED (a) on #656, split-opendox § 5.2) - #928
Conversation
FLOOR PART 1 outlives the tree it describes by exactly one act. Runbook § 5.2's shed deletes every MOVED row's source path and the one `deleted_at_carve` row — 319 of the 456 — and from that commit onward checks 3 and 4 refuse `carve-path-absent` by construction, which is right until the shed is ruled and useless the moment it is. RULED (a) POST-SHED MODE, Brett Heap 2026-09-10, verbatim "rule (a) post-shed mode" (`#656` comment `5625573095`). This is the capability only: the shed itself and the flip to `post-shed` are PR-2's, and this commit leaves the manifest in its `carve` phase over the current tree. `phase:` is an OPTIONAL top-level key closed to `carve` (what an absent key means) and `post-shed`, validated by check 1 — a document-level const in the same family as `digest_algorithm`, so a mistyped phase cannot reach check 3 and refuse there under a code naming a file. It is declared IN the manifest and there is deliberately no `--phase` flag: the § 8.2 required-suite seat runs the tool with no arguments, so a flag could never reach the floor at all, and a tree that verified or refused according to which job invoked the tool is the one property a floor may not have. It also makes the flip and the deletions one reviewable diff. Exactly two arms change. Check 3 pass 2, for a MOVED row, reads in the mirror: absence is the declared outcome and PRESENCE is the finding. Check 4 excludes the shed set — derived from the rows themselves, never from a second list — from `vanished`, and gains a mirror arm for the `deleted_at_carve` row that the digest loop never reads. Everything else is untouched in both phases. Check 2's ANCESTOR test stands (the shed deletes files from a tree, not a commit from a history), so check 3 PASS 1 still recomputes all 318 digests from the referent's real bytes and still bounds all 794 declared lines; check 4 still walks the referent, still refuses a file that has APPEARED under the surface, and still requires every `stays_*` and `replicated_at_destination` row PRESENT; checks 1, 5 and 6 never read the tree. No digest, disposition, `carve_commit` or `carve_tag` moves: `post-shed` is not a re-cut. The declaration is SYMMETRIC, which is what makes it a floor and not a mute: a `post-shed` manifest over a tree still carrying a moved row refuses the new `carve-shed-incomplete`, so the phase cannot be flipped ahead of the deletions to buy silence for 319 rows at once, and the deletions cannot land ahead of the phase. Runbook § 8's "no ordering of two commits leaves a green intermediate" stops being a discipline the lane is asked to keep and becomes the thing this file checks. Lane default (4): `carve-shed-incomplete` joins `REFUSAL_CODES` and its "FIXED, COMPLETE" note is amended to record that the extension is a ruled, diff-visible act, and that `RATIFIED_CODES` in the test restates the tuple so no member moves in silence. `REMEDIATION` gains the opposite remedy, because "re-cut the manifest" is wrong for this code. Lane default (5): check 4's `appeared` guard is unchanged under `post-shed`. The surface stays frozen. The `OK` line now names the phase on EVERY run, in both phases: a reader of a CI log must be able to tell which semantics answered without opening the manifest, and a line silent under the default would make the default the one state no log records. `--json` gains `phase` and `shed_rows`. Eleven tests, all subprocess-driven against real throwaway git trees on the file's own discipline, with each fixture's shed set derived from its own rows. The § 8.2 seat additionally asserts that the phase the run REPORTS equals the phase the file DECLARES, and the phase-specific sentence with it — so a phase-blind run, or one that silently fell back to the default, fails there rather than reading as green. Refs #656 Lane: openxfactory-4-opendox-extraction Co-Authored-By: Claude Fable 5.1 <[email protected]>
The document half of RULED (a) (Brett Heap, 2026-09-10, `#656` comment `5625573095`). No behaviour: the validator's semantics landed in the previous commit and the manifest stays in its `carve` phase, which is where it belongs until runbook § 5.2 runs. `docs/opendox-carve-manifest.yaml` carries `phase: carve` explicitly rather than by omission, with a header block giving the grammar (two values, absent means `carve`), what each phase requires of the tree, what `post-shed` does NOT move (`carve_commit`, `carve_tag`, every `sha256`, every disposition — it is not a re-cut), and the symmetry that makes the flip and the deletions one act. Written from the carve side, because that is the side a reader is on today. Lane default (3): the two places documenting `--at <carve_commit>` are corrected where they stop answering. At the carve commit every source path IS present, which is exactly what a `post-shed` manifest refuses, so from the shed commit onward that invocation returns `carve-shed-incomplete`. Both the manifest's own header block and runbook § 0.4 now say so and name the two remaining ways to ask about the carve's own line — check out a pre-shed revision, or read the digests straight out of git. It is deliberately not special-cased: a phase that could be satisfied two ways is a phase that says less. Runbook § 8 gains the post-shed paragraph — the flip rides in the same commit as the deletions, it is not a re-cut, and the floor CHECKS the atomicity rather than asking the lane to remember it — and § 11 records that a `carve-shed-incomplete` is not a re-cut trigger: it says the declared phase and the tree disagree, and its remedy is inside § 5.2. Lane default (8): § 8's shed test count was 3,426 and is MEASURED at 3,404, over the 319 paths the manifest's own rows derive, at `main` 554536f. The measuring command sits beside the number so the next reader re-derives it instead of carrying it: 319 shed paths, 3404 def test_ Refs #656 Lane: openxfactory-4-opendox-extraction Co-Authored-By: Claude Fable 5.1 <[email protected]>
There was a problem hiding this comment.
Sorry @brettheap, you've used your own review budget of 250,000 diff characters for the last 7 days.
You can request another review in 3 hours and 28 minutes by commenting @sourcery-ai review. Upgrade to get a review now.
Reviewer's GuideThis PR adds the capability for the carve-manifest validator to recognize a manifest-declared Sequence diagram for phase-aware carve manifest validationsequenceDiagram
participant Caller
participant Validator
participant Manifest
participant GitTree
Caller->>Validator: validate(manifest_path, repo)
Validator->>Manifest: read_manifest(manifest_path)
Validator->>Validator: check_shape(doc)
Validator->>Manifest: read phase
Validator->>GitTree: check_revision(repo, doc, at)
Validator->>GitTree: tree_at(carve_commit)
Validator->>GitTree: tree_at(verified_at)
Validator->>Validator: check_digests(..., phase)
alt phase is post-shed and MOVED source is present
Validator-->>Caller: carve-shed-incomplete
else phase is post-shed and shed sources are absent
Validator->>Validator: check_surface(..., phase)
Validator-->>Caller: OK phase post-shed
else phase is carve
Validator->>Validator: check_surface(..., phase)
Validator-->>Caller: OK phase carve
end
State diagram for the carve manifest lifecyclestateDiagram-v2
[*] --> carve
carve --> post_shed: same commit: delete shed rows + phase: post-shed
post_shed --> [*]
state carve {
[*] --> SourcePathsPresent
SourcePathsPresent --> SourcePathsPresent: MOVED paths present and verified
}
state post_shed {
[*] --> ShedPathsAbsent
ShedPathsAbsent --> ShedPathsAbsent: MOVED and deleted_at_carve paths absent
}
Flow diagram for post-shed source-path checksflowchart TD
A[Read manifest phase] --> B{phase is post-shed?}
B -- No: carve --> C[MOVED source must be present]
C --> D{Source absent?}
D -- Yes --> E[Refuse carve-path-absent]
D -- No --> F[Verify blob and mode]
B -- Yes --> G[Derive shed set from MOVED and deleted_at_carve rows]
G --> H{MOVED source still present?}
H -- Yes --> I[Refuse carve-shed-incomplete]
H -- No --> J[Expected absence passes]
J --> K{Non-shed source absent?}
K -- Yes --> L[Refuse carve-path-absent]
K -- No --> M[Post-shed validation passes]
File-Level Changes
Tips and commandsInteracting with Sourcery
Customizing Your ExperienceAccess your dashboard to:
Getting Help
|
There was a problem hiding this comment.
🟡 Changes recommended
A moderate remediation issue and several documentation/test nits remain unresolved.
Once you've addressed the issues Copilot identified, you can request another Copilot review.
Pull request overview
Adds manifest-declared carve and post-shed validation phases for the OpenDox lifecycle.
Changes:
- Enforces post-shed source absence and reports phase metadata.
- Adds subprocess and JSON coverage for both phases.
- Updates manifest and cutover documentation.
File summaries
| File | Review findings |
|---|---|
tests/carve_manifest/test_carve_manifest.py |
Rename the_manifests test for readability (nit, 1 vote). |
scripts/validate-carve-manifest.py |
Update grammar comments, clarify phase validation documentation (nits, 2 and 1 votes), and provide phase-specific remediation for retained rows (moderate, 1 vote). |
docs/opendox-cutover-runbook.md |
Clarify post-shed --at behavior, retained-row remediation, and derive measurements from the shared predicate (nits, 1 vote each). |
docs/opendox-carve-manifest.yaml |
Qualify the statement about invocation validity after the phase transition (nit, 1 vote). |
Review details
Suppressed comments (6)
docs/opendox-carve-manifest.yaml:20
- The header still says that “either invocation answers” from any descendant, but this new caveat makes the
--at <carve_commit>invocation refuse afterphase: post-shed. The primary verification instructions are therefore self-contradictory; qualify the earlier claim as pre-shed or state which invocation remains valid after the flip.
# THE SECOND ONE STOPS ANSWERING THE DAY `phase:` BELOW FLIPS TO `post-shed`:
# at the carve commit every source path is PRESENT, which is exactly what a
# post-shed manifest refuses (`carve-shed-incomplete`). From that commit on,
# ask about the carve's own line by checking out a pre-shed revision, or read
# the digests straight out of git
docs/opendox-cutover-runbook.md:1048
- This §11 rule still treats every
carve-path-absentas a re-cut trigger, but post-shed check 4 intentionally emits that code when a retainedstays_*or replica row is deleted. Re-cutting cannot restore a source that is already absent at the new referent and would weaken the retention guarantee; scope this rule to carve/moved-row drift and document the retained-row remedy separately.
`carve-digest-mismatch`, `carve-file-undeclared` or `carve-path-absent`
(a `carve-shed-incomplete` is NOT this: it says the manifest's declared phase
and the tree disagree, and its remedy is inside § 5.2, never a re-cut) — the
docs/opendox-cutover-runbook.md:951
- This measurement snippet hard-codes a second moved-disposition list instead of reusing the validator's
MOVED_DISPOSITIONSpredicate. If the disposition vocabulary changes, the documented 3,404 count can silently diverge from the actual shed set, despite this section saying the count is derived and not carried by hand; reuse the same source predicate here.
shed = [r["source_path"] for r in doc["rows"]
if r["disposition"] in ("moved_verbatim", "moved_with_declared_edit")
or r.get("reason") == "deleted_at_carve"]
scripts/validate-carve-manifest.py:29
- This says the other four checks are phase-blind, but check 1 now reads and validates
phaseat lines 751-761 before any Git call. Please distinguish check 1's document-level phase validation from checks 3/4's revision semantics; otherwise the ordered-check documentation contradicts the implementation.
Two of them read the revision under test and therefore read `phase:` — see
"THE TWO PHASES" below; the other four are phase-blind.
scripts/validate-carve-manifest.py:1506
- Under
post-shed, deleting a retainedstays_*orreplicated_at_destinationrow still raisescarve-path-absentin this branch, butCarveRefusal.render()appends the global remediation telling the caller to re-cut the manifest. A new carve commit cannot contain that missing source and re-cutting would incorrectly widen the shed; this path needs a phase-specific remediation (restore the retained row or correct the shed/manifest) instead of the re-cut guidance.
+ (". Under `phase: post-shed` a MOVED row and the "
"`deleted_at_carve` row are EXPECTED to be gone and are not "
"counted here — every row named above is a row that STAYS, and "
"the shed does not reach it"
if phase == PHASE_POST_SHED else ""))
tests/carve_manifest/test_carve_manifest.py:1830
- The new test name has a grammatical typo:
the_manifestsshould be singularthe_manifest. Renaming it keeps the test node readable and consistent with the manifest terminology used throughout this file.
def test_the_phase_is_the_manifests_and_not_a_command_line_flag() -> None:
- Files reviewed: 4/4 changed files
- Comments generated: 1
- Review effort level: Lite
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
Copilot (PRRT_kwDOTAvnrs6hQVzN): now that `phase` is accepted as another optional top-level key, the grammar comments still said `header:` is the only optional key and that every other key is required — the same wording repeated in check_shape's stray-key refusal message — so the documented grammar contradicted what check 1 actually accepts. Both spots corrected, comment/string text only, no behaviour change: * the TOP_LEVEL_KEYS comment now names `header:` and `phase:` as the two optional keys, states what each means (header is RULED OQ-E's convention-break prose; phase absent means `carve`), and points back at "THE TWO PHASES" for the full grammar. * the carve-shape-invalid message for an unknown top-level key now says "`header:` and `phase:` are its two optional keys; every other key is required" instead of naming `header:` alone. 209 carve_manifest + carve_arrival tests still pass; no test asserted the old wording verbatim. Refs #656 Lane: openxfactory-4-opendox-extraction Co-Authored-By: Claude Fable 5.1 <[email protected]>
There was a problem hiding this comment.
🔵 Needs a closer look
Add the missing carve-commit test and address the documented follow-up issues.
Review details
Suppressed comments (5)
Previously missed (1) — in code that hasn't changed since the last review.
tests/carve_manifest/test_carve_manifest.py:1830
- The new test name is grammatically incorrect (
manifestsis plural). Rename it totest_the_phase_is_the_manifest_and_not_a_command_line_flagso the test name clearly describes the invariant it checks.
docs/opendox-carve-manifest.yaml:20
- This caveat is added to the manifest and runbook, but the public README entry at
README.md:80still says--at b075fd91dc8fced8e1373825ba80220c33536baeasks about that revision without qualification. Once the manifest flips topost-shed, that invocation intentionally returnscarve-shed-incomplete, so please update the README in the same change to avoid advertising a command that no longer answers the carve revision.
# THE SECOND ONE STOPS ANSWERING THE DAY `phase:` BELOW FLIPS TO `post-shed`:
# at the carve commit every source path is PRESENT, which is exactly what a
# post-shed manifest refuses (`carve-shed-incomplete`). From that commit on,
# ask about the carve's own line by checking out a pre-shed revision, or read
# the digests straight out of git
scripts/validate-carve-manifest.py:1154
- Adding
phasechanges pass 2's behavior, but this docstring still describes pass 2 as always checking that the tested tree is unchanged from the carve. Inpost-shed, moved sources are intentionally absent, so the function contract should document the phase-specific presence/absence rule.
phase: str = PHASE_CARVE) -> int:
scripts/validate-carve-manifest.py:1357
- The new
phaseparameter makes this function intentionally allow the manifest-derived shed set to be absent, but the docstring still promises that every surface file appears at the tested revision. Please update the contract to mention thepost-shedexception so future callers do not read the old guarantee as still universal.
phase: str = PHASE_CARVE) -> int:
tests/carve_manifest/test_carve_manifest.py:1788
- This test is documented as exercising
--at <carve_commit>, but aftershed()scratch.headis the post-shed commit, so it only covers the normal HEAD tree. The actual carve commit (doc["carve_commit"]), where all moved rows are present and must triggercarve-shed-incomplete, is not tested.
done = run(scratch, "--at", scratch.head)
- Files reviewed: 4/4 changed files
- Comments generated: 0 new
- Review effort level: Lite
|
…endox; brainstorm) (#929) Files the § 5.2 shed-exit design note (the measurement agent's spike report of 2026-09-10) into `ideation/brainstorm/` and indexes it in `ideation/README.md`, so the measurement behind Brett Heap's RULING (a) POST-SHED MODE survives scratchpad loss. What it measured: exit (a) works — the carve-manifest validator answers OK over the full 319-row shed tree, both carve suites green at 209 passed, zero disposition changes, a 482-added / 17-removed diff across 4 files (realized as #928). The shed also exposes an unbudgeted adapter re-point — 104 import sites across 32 files naming 32 shed modules, 17 of them unreachable without an openDox mount (→ RULED Q7, the second submodule), the retained `tests/ideation-dashboard/conftest.py:106` import that aborts collection (→ RULED Q6), and a six-schema `contracts/schemas/` family still named by 127 tracked files (→ RULED Q2) — and costs exits (b) RE-CUT and (c) RETIREMENT. Provenance: #656 comments 5624521801 (ruling request), 5625144570 (measured addendum), 5625573095 (RULING (a)). The measurement text is verbatim from the lane's scratchpad note; the header and `## Provenance` are adapted to the brainstorm-doc format; three dated editor's notes (`> **Editor's note (filing, 2026-09-10):**`) correct a `verified_at` sha inconsistency (88caf62e vs b27f0555 — two distinct commits on the spike chain), date the since-superseded "CI inits only openXwallet" claim (#917 → edf0e24 widened the init), and pin the Appendix's reproduction clone — all added beside the original text without rewriting it, as the brainstorm stage allows. No `openspec/changes/` path. Independent check (sonnet fix round, 2026-09-10): 6 Copilot threads all resolved with real edits or notes; 0 closing references in body and commits; pytest-suite run 34538910209 success; six required checks green. Refs #656 (stays OPEN). Lane: openxfactory-4-opendox-extraction Co-Authored-By: Claude Fable 5.1 <[email protected]>
… 5 review threads Mirrors PR #917 file-for-file for the remaining pieces task 5.1's extension owes (docs/opendox-cutover-runbook.md § 7; RULED Q7, #656 comment 5626248666): - scripts/doc_health/pin_class.py: two new PinMember entries beside the openxdox-pin-* pair (opendox-pin-carve-commit REPO_LOCAL, opendox-pin-product-commit CROSS_REPOSITORY), both keyed on contracts/opendox-pin.yaml. Measured with pin_class.verify(): standing census 73,26 -> 75,28 (81 results / 29 members on this tree; 79 / 27 on origin/main at 85fb856), uncovered/vanished/arrived all untouched. - tests/doc-health/test_sentinel_vocabulary.py: the census step recorded and the frozen-pair assertion moved to (75, 28), measured the same way against main, never by arithmetic. - .github/workflows/pytest-suite.yml: the init step now also initializes openDox, so tests/opendox_pin/'s positive case (and its lockstep check, which reads openXdox's own derived pin) run against the real checkout in CI. openDox/code is not initialized and is not needed here. - docs/opendox-cutover-runbook.md § 7: a dated amendment recording that RULED Q7 supersedes RULING F for openDox alone, quoting the ruling, naming the lockstep invariant, and noting design.md's matching sentence is amended by PR-2's packet patch rather than here. - contracts/README.md: a doc-index row for contracts/opendox-pin.yaml in the Native openxFactory contracts table, alongside openxwallet-pin.yaml's and openspec-cli-pin.yaml's own rows (openxdox-pin.yaml has no row of its own to sit beside; the row says so rather than papering over it). Addresses all 5 open review threads on the first commit: 1/2. tests/openxdox_pin/test_openxdox_pin_verifier.py's test_ruling_f_is_checkable_no_opendox_pin_and_no_second_gitlink asserted RULING F (no second pin, no second gitlink), which RULED Q7 supersedes for openDox. Renamed to test_ruling_q7_two_direct_upstreams_in_lockstep: it now asserts exactly two product gitlinks (openDox, openXdox) and the LOCKSTEP equality between contracts/opendox-pin.yaml's commit and the commit openXdox/contracts/opendox-pin.yaml names, read as a git blob at the openXdox gitlink's own commit rather than through the working tree. The docstring carries the supersession (ruling ids, date). 3. scripts/verify-opendox-pin.py's _openxdox_derived_commit read openXdox/contracts/opendox-pin.yaml from the mutable working tree, so an edit there that never moved the openXdox gitlink could satisfy or defeat the lockstep check regardless of what is actually pinned. Rewritten to resolve the openXdox gitlink (_recorded_gitlink, HEAD then the index, exactly as check 2 does for openDox) and read the blob at that commit with `git show <oid>:contracts/opendox-pin.yaml` against the openXdox submodule's own object store. Every failure to locate the gitlink or read or parse the blob refuses pin-unreadable (an environment fact, not one of the six governed codes) naming the init command. 4. load_pin()'s `except (OSError, yaml.YAMLError)` did not catch UnicodeDecodeError, so a non-UTF-8 pin file would crash main() with a traceback instead of the documented fail-closed refusal. Added UnicodeDecodeError to that clause; the rewritten _openxdox_derived_commit decodes the git-show blob by hand and catches the same error there. 5. Added tests/opendox_pin/test_opendox_pin_verifier.py, a hermetic suite of the same shape as tests/openxdox_pin/'s own: every one of the six opendox-pin-* refusal codes exercised (the five mirrored from openxdox-pin-*, plus the new lockstep-mismatch), a scratch fixture with TWO nested repositories (openDox, with its own nested leg gitlink, and openXdox, holding only the derived pin file check 5 reads), and the regression test the fix above exists to pass: test_editing_the_openxdox_working_tree_pin_does_not_fool_lockstep edits that file on disk, without moving the openXdox gitlink or committing, and asserts verify() is unmoved because it never reads that file. Verified locally: both submodules initialized (git submodule update --init openDox openXdox); `python3 scripts/verify-opendox-pin.py` and verify-openxdox-pin.py both OK; `pytest tests/opendox_pin tests/openxdox_pin tests/doc-health/test_sentinel_vocabulary.py` 140 passed; validate-carve-manifest.py OK (456 rows, unchanged); `pytest tests/carve_manifest tests/carve_arrival` 209 passed (grown from PR #917's own measured 198 by #928, landed on main after #917 and before this branch was rebased onto it; neither directory is touched by this commit). openDox main sha bound live via `gh api repos/opensoft/openDox/branches/main`, matches the pinned 49a99df2...; the sorted-ls-tree-r-v1 digest independently recomputed from a separate fresh clone equals the pin's recorded 96655ad2...; openXdox's own contracts/opendox-pin.yaml at db58fffa... names the same 49a99df2... commit this pin does. Refs #656 (stays OPEN). Refs #872. Lane: openxfactory-4-opendox-extraction Co-Authored-By: Claude Fable 5.1 <[email protected]>



Lane: openxfactory-4-opendox-extraction (formerly openxfactory-opendox)
Refs #656 —
split-opendox-two-layer-product§ 5.2, FLOOR PART 1.The ruling this realizes
RULED 2026-09-10, Brett Heap, verbatim: "rule (a) post-shed mode, merge 924 when green" — recorded at #656 comment
5625573095:This is PR-1, the capability only. The shed itself — the 319 deletions and the flip to
phase: post-shed— is PR-2, and is not startable until the ruling's three open sub-questions (2), (6) and (7) have words. The manifest here stays in itscarvephase and the validator answersOK … phase carveover the current tree.The problem
docs/opendox-carve-manifest.yamloutlives the tree it describes by exactly one act. Runbook § 5.2's shed deletes every MOVED row's source path and the onedeleted_at_carverow — 319 of the 456 — and from that commit onward checks 3 and 4 refusecarve-path-absentby construction. Measured on a throwaway shed tree with the unmodified validator:1 failed, 197 passed, reproducing PR #924's probe exactly. That refusal is right until the shed is ruled and useless the moment it is.What changes
phase:is an OPTIONAL top-level key closed tocarve(what an absent key means) andpost-shed, validated by check 1 — a document-level const in the same family asdigest_algorithm, so a mistyped phase cannot reach check 3 and refuse there under a code naming a file.In the manifest, and there is deliberately no
--phaseflag. The § 8.2 required-suite seat runs the tool with no arguments, so a flag could never reach the floor at all; a tree that verified or refused according to which job invoked the tool is the one property a floor may not have; and declaring it in the document makes the flip and the deletions one reviewable diff.test_the_phase_is_the_manifests_and_not_a_command_line_flagasserts--phaseis absent from--help.Exactly two arms change semantics:
carvepost-shedcarve-shed-incompletevanished, incl.deleted_at_carve(1)deleted_at_carverow still presentThe shed set is derived from the rows themselves (
MOVED_DISPOSITIONS, orreason == "deleted_at_carve"), never from a second list, in the validator and in every test alike — so nothing has to be kept in step by hand.The declaration is symmetric, which is what makes it a floor and not a mute. A
post-shedmanifest over a tree still carrying a moved row refuses, so the phase cannot be flipped ahead of the deletions to buy silence for 319 rows at once, and the deletions cannot land ahead of the phase. Runbook § 8's "no ordering of two commits leaves a green intermediate" stops being a discipline the lane is asked to remember and becomes the thing this file checks.What does NOT change
appearedguard are untouched — a file appearing under the surface still refusescarve-file-undeclaredin both phases.stays_openxfactory_adapter(103),stays_openxfactory_governance(14) andreplicated_at_destination(20) are still required PRESENT in both phases.carve_commit, nocarve_tagmoves.post-shedis not a re-cut and cuts no tag.Zero lines in the five surfaces the ruling fenced off:
scripts/verify-carve-arrival.py,scripts/carve_lines.py,tests/carve_arrival/,.github/(includingpytest-suite.yml) andopenspec/changes/. No file is deleted.pytest-suite.ymlneeds no edit: the 11 added tests raise SELECTED and PASSED, which are floors that may only rise, and add no skip.What
post-shedgives up, stated plainly: for the 318 moved rows only, it stops asking "has this file drifted onmainsince the carve". That cannot be asked of a deleted file under any exit, and the answer it was buying is discharged once and elsewhere — at the four destinations, byverify-carve-arrival.py, against blobs read atcarve_commitfrom this repository's own history, which the shed does not touch. The 137 rows that stay keep every guarantee they had.Lane defaults taken
--at <carve_commit>corrected in both places it stops answering. At the carve commit every source path IS present, which is exactly what a post-shed manifest refuses — so from the shed commit onward that invocation returnscarve-shed-incomplete. The manifest's own header block and runbook § 0.4 now say so and name the two remaining ways to ask about the carve's own line: check out a pre-shed revision, or read the digests straight out of git. Deliberately not special-cased — a phase that could be satisfied two ways is a phase that says less. Pinned bytest_the_carve_commits_own_line_refuses_under_a_post_shed_manifest.carve-shed-incompleteis inserted beforecarve-unreadable, and the note now records that the extension is a ruled, diff-visible act; that "FIXED, COMPLETE" states what the vocabulary owes a caller (every code a check can raise is in it, and nothing raises a code outside it) rather than promising never to extend it; and thatRATIFIED_CODESrestates the tuple as a literal so no member moves in silence.REMEDIATIONgains the opposite remedy, because "re-cut the manifest" is wrong for this code.appearedguard stays as-is underpost-shed. Pinned bytest_a_file_appearing_under_the_surface_still_refuses_post_shed.554536f6:319 shed paths, 3404 def test_.The
OKline reports the phase, on every runIn both phases, not only the new one: a reader of a CI log must be able to tell which semantics answered without opening the manifest, and a line silent under the default would make the default the one state no log records. It is also what lets the § 8.2 seat assert the run took the branch the document declares.
--jsongainsphaseandshed_rows.Tests: 198 → 209
The eleven added cases are subprocess-driven against real throwaway git trees, on the file's own discipline.
tests/carve_arrivalis unchanged at 91.The § 8.2 seat
test_the_real_repository_answers_at_the_ruled_pathadditionally reads the declared phase out of the YAML and requires it to equal the phase the run reports, plus the phase-specific sentence — so a phase-blind run, or one that silently fell back to the default, fails there rather than reading as green.Verification, verbatim
Over this branch (pre-shed,
phase: carve):Synthetic post-shed check — a throwaway copy of this branch with the 319 rows' source paths deleted (derived from the manifest, never listed) and
phase: post-shed, since discarded:Both directions of the symmetry, on the real repository — restore one shed file under a post-shed manifest, and flip the phase over the unshed tree:
Governance
No
openspec/changes/path — this is a plain gate and lands on the lane's word. The change packet's design.md amendment for the post-shed mode is owed to PR-2 (the shed), not to this PR. Rule 6's landing window does not apply.Measured source: the exit-(a) spike's design note (721 lines,
Status: brainstorm), which this lane is filing intoideation/brainstorm/separately. Two numbers were re-measured at this branch's base and both held: 3,404def test_across the 319 shed paths, and 209 passing carve tests.One correction to the ruling's own text, for the record: it calls
carve-shed-incomplete"the seventh refusal code", which is the design note's Q4 wording. The tuple as landed carries twelve members, and the new one is the eleventh by position (inserted beforecarve-unreadable). Nothing in the ruling's substance turns on the ordinal.Reviewers welcome — Copilot and Sourcery on the usual lane terms.
🤖 Generated with Claude Code
Summary by Sourcery
Add a manifest-declared post-shed validation phase that makes the carve shed and phase transition an atomic, fail-closed operation.
New Features:
carve/post-shedphase that allows validation to continue after the ruled source-file shed while preserving all unaffected checks.Bug Fixes:
deleted_at_carvesource rows as ordinary missing-path failures.carve-shed-incompletefor trees whose files and declared post-shed phase are out of sync.Enhancements:
--atexpectation, and the corrected shed-related test count in the cutover runbook.Documentation:
Tests:
Chores: