openhuman icon indicating copy to clipboard operation
openhuman copied to clipboard

storage-bypass: artifacts box_source stages box files with std::fs::write

Open senamakel opened this issue 3 weeks ago • 2 comments

crates/openhuman-core/src/artifacts/box_source.rs (stage()) copies bytes read from a sandbox box into a per-call scratch folder under the workspace staging dir with std::fs::write, because tiny_artifacts::CreateArtifactTool/UpdateArtifactTool take a file path as source. The folder is owned by a Staged guard and removed after the call, so it is transient scratch, not record state. It trips the storage-bypass guard (json-write), which currently fails on main.

Follow-up: once tiny-artifacts can take bytes (or a BlobStore handle) for a file source, stage through the storage port and drop the allowlist entry in scripts/ci/storage-bypass-allow-reasons.json. Related: #7425.

senamakel avatar Nov 10 '26 23:11 senamakel

box_source::stage() writes transient scratch files with std::fs::write, tripping the storage-bypass (json-write) guard that currently fails on main; needs either an allowlist entry with a reason or a refactor to stage through the storage port once tiny-artifacts accepts bytes/BlobStore handles.

Labelled priority: p2.

tinysweeper avatar Nov 10 '26 23:11 tinysweeper

Not needed yet; fixing in the storage layer

senamakel avatar Nov 10 '26 23:11 senamakel