MCPcopy Create free account
hub / github.com/NVIDIA/OpenShell / write_sandbox_request

Function write_sandbox_request

crates/openshell-driver-vm/src/driver.rs:4427–4434  ·  view source on GitHub ↗
(state_dir: &Path, sandbox: &Sandbox)

Source from the content-addressed store, hash-verified

4425}
4426
4427async fn write_sandbox_request(state_dir: &Path, sandbox: &Sandbox) -> Result<(), std::io::Error> {
4428 restrict_owner_only_dir(state_dir).await?;
4429 write_private_file(
4430 &state_dir.join(SANDBOX_REQUEST_FILE),
4431 sandbox.encode_to_vec(),
4432 )
4433 .await
4434}
4435
4436async fn read_sandbox_request(path: &Path) -> Result<Sandbox, std::io::Error> {
4437 let bytes = tokio::fs::read(path).await?;

Calls 2

restrict_owner_only_dirFunction · 0.85
write_private_fileFunction · 0.85

Tested by

no test coverage detected