A step can write the package caches every later run reads #495

Open
opened 2026-11-11 17:44:38 -05:00 by cmoriarty · 0 comments
Owner

What happens
Each sandbox (braid#203) holds the shared npm store, the uv cache and the Playwright browser cache read-write, because installs write them. So one run's step can change what a later run installs. npm checks an entry's hash when it reads it; uv's unpacked wheels are not checked again. The shared cache is also never pruned: about 2.8 GB on 2026-11-11, against 840 MB on 10-18.

Fix (to design)
Options: a read-only store with a writable layer for each run, merged by osfd after a check; uv's --verify-hashes where a lock has hashes; and a prune by age.

Done when
A sim in which one run's step rewrites a cached package shows the next run installing the original, and the cache has a size it stays under.

**What happens** Each sandbox (braid#203) holds the shared npm store, the uv cache and the Playwright browser cache read-write, because installs write them. So one run's step can change what a later run installs. npm checks an entry's hash when it reads it; uv's unpacked wheels are not checked again. The shared cache is also never pruned: about 2.8 GB on 2026-11-11, against 840 MB on 10-18. **Fix (to design)** Options: a read-only store with a writable layer for each run, merged by osfd after a check; uv's `--verify-hashes` where a lock has hashes; and a prune by age. **Done when** A sim in which one run's step rewrites a cached package shows the next run installing the original, and the cache has a size it stays under.
Sign in to join this conversation.
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
cmoriarty/braid#495
No description provided.