pub(crate) fn capture_while_running(
fs: &FileStore,
uid: &str,
dir: &Path,
settle: Duration,
) -> Result<usize, StoreError>Expand description
Record what the provider wrote to dir while the agent runs — the drift
detector’s hook (SPEC_MEMORY_FOLLOWS_THE_AGENT_2026_09_24.md §2.1.3).
Capture only: nothing is written to the folder. Only a folder a spawn
has already reconciled (it holds projections), whose claim uid still
holds alone, and only files unchanged for settle (CAPTURE_SETTLE).
Returns how many versions were recorded.