pub fn install_parts_library(incoming: &PartsLibraryMap) -> boolExpand description
INSTALL a library wholesale — the app → history-runner channel (the runner owns its own thread-local store, and the per-run request no longer carries the block, so this is how a background thread/worker learns the library).
Unlike [ingest] (fill-only, resident-wins) this makes the store MATCH
incoming BY CONTENT IDENTITY, which is what a cache channel needs:
- a name missing from the store is inserted (stamped + hashed like ingest);
- a name whose resident entry has the SAME identity is KEPT VERBATIM — that
is what protects a runner-side heal, whose only trace is a rewritten
snapshot, from being clobbered by a re-send; - a name whose resident entry has a DIFFERENT identity is REPLACED and
marked
dirty, so the ACOMP self-heal lane re-derives every instance (dirtyis#[serde(skip)]and cannot ride the wire — it is derived HERE, from the identity mismatch); - a resident name ABSENT from
incomingis dropped.
Returns whether anything changed (and bumps the revision if so).