Merge imported products into local session state

This commit is contained in:
2026-12-02 16:24:33 +00:00
parent ad8a5df97b
commit e7fada4372
26 changed files with 638 additions and 1254 deletions

View File

@@ -579,9 +579,7 @@ Publish commit model:
`current/commit-pointer.json` is the remote current-state commit marker. It
selects exactly one immutable commit, which declares the complete object set.
The current restore implementation still expects a published execution ledger;
new publications cannot be restored until the inventory-based restore cutover
described in the [implementation roadmap](roadmap/implementation.md) lands.
Restore reads that inventory without fetching an execution ledger.
## Remote Commit Migration
@@ -641,7 +639,8 @@ narratio session locks remove 2026-04-04 narratio.artifact.session_recap
## Restore Workflow
Use restore when local durable session state is missing or stale and remote committed current state is authoritative.
Use restore to import products from the selected publication into a local session.
Existing local progress is retained where its evidence remains valid.
Dry run:
@@ -665,8 +664,8 @@ content verification. It does not certify that an import or pipeline run occurre
Default restore scope:
- the committed session manifest, prepared inputs, and transcript/artifact
objects declared by the selected remote commit
- prepared inputs and currently recognized transcript/artifact products declared
by the selected remote commit
- `inputs/previous/**` when needed by enabled targets or their configured
prerequisites, including disabled prerequisites; each is selected from its
exact committed `published_output` declaration
@@ -677,6 +676,12 @@ Optional:
- `--force` to overwrite eligible conflicting regular files; it never replaces
directories, symlinks, or other non-regular local targets
Verified products without valid local execution evidence receive local supplied
product records. Identical files preserve valid local execution evidence. Changed
products invalidate dependent local work; unrelated checkpoints are preserved.
This import does not claim that the remote execution occurred locally, and
`--force` here authorizes replacement rather than pipeline regeneration.
Restore treats a local leaf symlink or any symlinked ancestor beneath the
selected session root as a conflict, even when the linked content matches the
selected remote object. `--force` does not override that conflict.
@@ -692,7 +697,7 @@ If restore fails after beginning installation, it leaves a durable
`.restore-incomplete.json` marker in the session root. Pipeline runs will stop
until you rerun the same restore command and it completes. Restore intentionally
does not try to roll back files already installed; retrying the selected remote
snapshot is the recovery procedure.
publication is the recovery procedure.
## Local State Layout