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

Function compute_error_from_status

crates/openshell-server/src/compute/mod.rs:1823–1829  ·  view source on GitHub ↗
(status: Status)

Source from the content-addressed store, hash-verified

1821}
1822
1823fn compute_error_from_status(status: Status) -> ComputeError {
1824 match status.code() {
1825 Code::AlreadyExists => ComputeError::AlreadyExists,
1826 Code::FailedPrecondition => ComputeError::Precondition(status.message().to_string()),
1827 _ => ComputeError::Message(status.message().to_string()),
1828 }
1829}
1830
1831fn decode_sandbox_record(record: &ObjectRecord) -> Result<Sandbox, String> {
1832 Sandbox::decode(record.payload.as_slice()).map_err(|e| e.to_string())

Callers

nothing calls this directly

Calls 2

codeMethod · 0.80
messageMethod · 0.80

Tested by

no test coverage detected