You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
id: import ingest — apply a verified export under normal admission rules with a per-entry report (§6.2 step 4; slice 4b of #2852, from #3810) #13158
Slice 4b (ingest half) of #2852, remainder of #3810. The §6 core — export format + import verification (§6.2 steps 1–3) — landed in PR #9396 as slice 4a (pkgs/id/src/hosted_export.rs: build_export / verify_import, 9 tests green at main 3a941eff430e, verified 2026-11-23). What 4a deliberately left, in its own module doc: "Ingest itself (§6.2 step 4) follows the platform's normal rules and is likewise downstream of a verified import."
Scope
Apply a verified export at the importing (self-hosted) node:
Downstream of verify_import only — an export that fails any §6.2 step 1–3 rule ingests nothing (already guaranteed by 4a; this slice must not weaken it).
Round-trip test: store → export → verify_import → ingest into a fresh node; the target's canonical object/hash set is identical to the export's set.
Re-ingesting the same export is idempotent: every entry reports already-present, nothing double-applies.
An entry that passes verification but fails a normal ingest rule (e.g. validity at ingest) is refused, named in the report with its rule, and does not block the remaining entries.
Blobs land by hash and are retrievable from the target node's blob store after ingest.
Pickup (Lane QJ, archer): working this now — import ingest (§6.2 step 4) downstream of verify_import: per-object ingest under normal admission rules, blobs placed by hash, per-entry outcome report (applied / already-present / refused-with-rule). Acceptance per the issue: round-trip identity, idempotent re-ingest, refused entries named without blocking the rest, blobs retrievable by hash. Worktree off current main on the laptop; premise check first (4a core hosted_export.rs on main).
Done — Lane QJ (archer), 2026-11-23. Landed via PR #13201, merged c7ef51fbf859 (head SHA-guarded at 0785bdbe236f); this issue auto-closed via the PR body.
What landed: new pkgs/id/src/hosted_ingest.rs — ingest_import applies a verified export at the importing node (§6.2 step 4):
Requires the VerifiedImport token from verify_import and checks it names this export's binding, key, and counts; a mismatch is refused before any write.
Objects go through EventStore::ingest — the store's normal verification/fork/waiting rules, no privileged path. Waiting-held objects are settled after the whole export is offered; one still waiting is reported refused under the waiting rule (its held row stays, so a later import carrying the dependency releases it).
Blobs are placed in the node's iroh-blobs store under the BLAKE3 hash of their bytes — the hash a document.put header cites — so citations resolve locally.
ImportReport names every object and blob as applied / already-present / refused-with-rule; a refusal never blocks the remaining entries.
Verification (laptop, nix develop in pkgs/id):cargo test -p id --lib hosted_ → 57 passed, 0 failed (5 new tests covering each acceptance line: round-trip identity + blob retrievable by cited hash, idempotent re-ingest, malformed-object refusal named and non-blocking, missing-predecessor waiting refusal, foreign token writes nothing). Full cargo test -p id --lib → 531 passed, 0 failed. Clippy clean; rustfmt clean on the new file. hosted_export's module doc now points at the new module for step 4.
#3810 stays open as the slice-4b tracker: its remaining half is #13157 (hosted export production — DO enumeration + R2 fetch feeding build_export).
Activity
developing-today commentedon Nov 23, 2026
CODE-4799
dezren39 commentedon Nov 23, 2026
Pickup (Lane QJ, archer): working this now — import ingest (§6.2 step 4) downstream of
verify_import: per-object ingest under normal admission rules, blobs placed by hash, per-entry outcome report (applied / already-present / refused-with-rule). Acceptance per the issue: round-trip identity, idempotent re-ingest, refused entries named without blocking the rest, blobs retrievable by hash. Worktree off current main on the laptop; premise check first (4a corehosted_export.rson main).Merge pull request #13201 from developing-today/lane-qj-13158
dezren39 commentedon Nov 23, 2026
Done — Lane QJ (archer), 2026-11-23. Landed via PR #13201, merged
c7ef51fbf859(head SHA-guarded at0785bdbe236f); this issue auto-closed via the PR body.What landed: new
pkgs/id/src/hosted_ingest.rs—ingest_importapplies a verified export at the importing node (§6.2 step 4):VerifiedImporttoken fromverify_importand checks it names this export's binding, key, and counts; a mismatch is refused before any write.EventStore::ingest— the store's normal verification/fork/waiting rules, no privileged path. Waiting-held objects are settled after the whole export is offered; one still waiting is reported refused under the waiting rule (its held row stays, so a later import carrying the dependency releases it).document.putheader cites — so citations resolve locally.ImportReportnames every object and blob as applied / already-present / refused-with-rule; a refusal never blocks the remaining entries.Verification (laptop,
nix developin pkgs/id):cargo test -p id --lib hosted_→ 57 passed, 0 failed (5 new tests covering each acceptance line: round-trip identity + blob retrievable by cited hash, idempotent re-ingest, malformed-object refusal named and non-blocking, missing-predecessor waiting refusal, foreign token writes nothing). Fullcargo test -p id --lib→ 531 passed, 0 failed. Clippy clean; rustfmt clean on the new file.hosted_export's module doc now points at the new module for step 4.#3810 stays open as the slice-4b tracker: its remaining half is #13157 (hosted export production — DO enumeration + R2 fetch feeding
build_export).Merge main into lane-qn-13157 (reconcile with #13158 ingest)