Skip to content

Add verified packed-catalog storage and publication foundations - #20

Merged
forhappy merged 42 commits into
mainfrom
codex/packed-catalog-publication
Oct 3, 2026
Merged

forhappy merged 42 commits into
mainfrom
codex/packed-catalog-publication

Conversation

@forhappy

@forhappy forhappy commented Oct 1, 2026 •

Copy link
Copy Markdown
Contributor

Large Git histories need canonical object lookup and durable publication without an authoritative per-object placement inventory in the Repository Cell. This PR adds verified immutable pack/catalog storage, retained generation facts, fenced publication foundations and fair bounded command dispatch. The latest increment prepares exact native push outcomes as immutable artifacts and signs a joint catalog/ref/outcome input bounded by 8 KiB.

Resulting behavior

  • Shared authenticated indexes and snapshots store immutable pack/catalog/ref metadata. Physical verification, canonical overlap/typed dependency checks and retained closure bind preparation to its own queried base and storage capability.
  • Creating-attempt namespaces and independent pins preserve original inputs through staging, Claim, reconciliation and uncertain command outcomes. Staging and publication share bounded account/class-fair dispatch.
  • Fresh empty initialization installs catalog/ref roots atomically. Immutable ref state reuses RangeIndex/NodeRef and RefExpectation, preserves tombstone versions, coalesces changed paths and carries joint roots through generations and compaction.
  • Direct-push policies prepare in pages of at most 128 updates/256 KiB. Rare configuration changes advance an epoch; indexed exact required-run dependencies handle ordinary CI changes. Guard registration and bounded cleanup are transactional.
  • The new private root-completion factory requires exact registered native checkpoint custody and its original successful plan. It freezes success, publication rejection and signed-certificate-replay rejection outside the Cell, then binds their descriptors, ref generation and ownership facts in the completion certificate. New artifacts use the current admitted namespace; adopted native bytes can retain their original namespace. Existing metadata roots and native audit descriptors are reused.

Validation

  • Workspace library suite: 473 unique tests passed (6 Git-format, 14 object-storage, 453 server). This includes existing native receive/publication/cold-clone and owner/lease/checkpoint recovery checks.
  • Four new completion tests passed again after the representation-only lint correction: real SHA-1/SHA-256 receives with 257 refs over three policy pages, an input below 2 KiB, exact frozen responses, eight tamper cases per format, stale-policy refusal, signing-key codec bounds, no-report-status rejection and late-part corruption.
  • All-target workspace Clippy passed with warnings denied. Three retained-catalog startup/refusal integrations passed. Formatting, diff checks and 58 local document links passed.
  • Earlier failed fixture/probe/lint runs and their causes remain recorded in the implementation status. Both CI runs at the previous 8bb0ee7 head succeeded; new-head CI is separate evidence.

Required implementation and release gates

The full implementation and capacity goal remains open. Preparation is conditional and grants no acknowledgement. The final bounded atomic root/outcome command must check actual fence, current ACL/lease/pin/guard, exact catalog CAS and signed ownership while recording the selected outcome. Immutable outcome-only completion, authorized durable replay, complete typed retention/collection and isolated restore, supervised takeover, coordinated producer/reader/schema hard cutover, file-backed intent/report handling, hard OS containment, accelerated reads/physical pack rewriting, continuous fair maintenance and hot-root progress remain required. Full-history Linux/Kubernetes/Chromium and the mandatory 10,000-developer mixed-load campaign remain unqualified.

The executable scope and remaining gates are in the implementation plan, large-team amendment, storage design and immutable outcome contract.

The previous 63,965-byte PR description is archived verbatim, including its historical validation and failures. This preserves the evidence while keeping the current description within GitHub's size limit.

@forhappy
forhappy marked this pull request as ready for review October 2, 2026 00:52
Bind exact retained descriptor membership and live successor authority to physical closure preparation. Preserve original source incarnations while writing successor index nodes, carry the checkpoint digest through catalog certificate v3 and reconciliation, and recheck custody in final publication.

Extend owner restoration through publication. Completion retires the active operation, so verify its retained independent pin and original exact checkpoint receipt rather than expecting an active query after completion.

Validation: 379 workspace library tests, all-target Clippy with warnings denied, formatting and diff checks pass locally. Prior-head CI fails native capture with WouldBlock; record that unresolved failure without weakening fences or deadlines.
Closing a CLOEXEC file in the parent does not release its exclusive lock while an unrelated pre-exec child still holds an inherited copy. Explicitly unlock only when the final capture file owner drops, preserving queued upload exclusion and native worker descendant drain.

The deterministic regression reproduces WouldBlock before the fix on macOS and Linux and passes afterward. All 380 unique library tests pass locally and in an unprivileged Linux container; all-target Clippy with warnings denied passes. The precise failing phase of the earlier CI run remains unproven and fresh CI is required.
Reuse publication dispatch and per-job byte reservations for adopted checkpoints. Preserve original committed receipts separately from fresh custody and fence unusable bound sessions. Cover cancellation, uncertain recovery, authority changes, retained physical publication and mixed admission.
Retain Claim and Renew commands through shared publication admission, cancellation, close and uncertainty recovery. Preserve original receipts separately from fresh lease custody and reuse the shared session fence and generation pins. Cover owner restoration, original floors, authority races and retained physical publication.
Reuse operation admission, exact commands, worker/result slots and checkpoint ownership after Bind or bound Claim. Share session deadlines and permanent fences with bases and enforce a separate residence ceiling without a renewal loop. Preserve known receipts across failed fresh custody and cover cancellation, closed recovery, owner restore and native assembly.
Reuse authenticated artifacts, GitInput and the native input index for request-only checkpoints, exact append CAS and restored-owner reopening. Compute scoped and raw digests in one scan and retain spool admission through queued cancellation.

The completed staging checkpoint slot previously refused the real native append. Permit only exact-predecessor replacement after known success, preserving unknown commands and original observers. Reject simultaneous Bind and append in SQL. Production cutover, durable native results and final ref-plan roots remain open.
Reuse the shared range tree and canonical ref plan for byte-bounded lexical keys, tombstones, weighted live seeks, exact conditional updates and streaming initial construction. Advance exhausted seek branches to later ancestor siblings so namespace validation cannot miss live descendants.

Validate with 437 workspace library tests, all-target Clippy, stock-Git HTTP and signed-push recovery. Final root publication, existing-base bulk coalescing and production hard cutover remain open.
Reuse unaffected subtrees through a bounded sorted rewrite, preserve full expectation validation and canonical intent digests, and balance final leaf/internal groups. Release spool admission before disk credit so observable cleanup cannot race permit release.

Validated with 443 workspace library tests, 1,000 queued-spool cancellation repetitions, all-target Clippy, and stock-Git HTTP and signed-push integrations. Authoritative root publication, serving cutover, and large-team capacity qualification remain outstanding.
Carry the selected ref descriptor through shared generation facts, lease/frontier queries and catalog attestations. Derive conditional ref transitions only from the prepared catalog capability, retain the exact descriptor through compaction, and refuse inline SQL writes against a selected root.

Use one encoded context in the new v4 attestation payload to retain the existing 1 KiB bound. Eliminate the observed SSH fixture port-probe race. Verified with 447 library tests, all-target Clippy and HTTP, signed-push restore and RSA/ECDSA integration checks. Fresh initialization, final policy/check authority, short atomic publication and full cutover remain outstanding.
Use the merged Cellule owner-fence API and retain listener and native cleanup regression coverage. Scope retained Directory fixtures without accepting historical Repository code. Workspace libraries, final all-target Clippy, Python harness, and focused integrations pass.
Preserve bounded indexes, native admission and gateway-owned cache lifetime. Keep the prerequisite release rejection check and benchmark source identity regression. Updated compatibility tests, 96 Python harness tests and all-target Clippy pass.
@forhappy
forhappy merged commit 6ee30e7 into main Oct 3, 2026
4 checks passed
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.

1 participant