Skip to content

An agent-managed museum exhibit, built in Rust with Gajae-Code / LazyCodex — developed and maintained with no human intervention.

Rust

fix: add status field to sandbox JSON envelope (ok/warn/error derived from enabled+active+supported)

YeonGyu-Kim85e736c73ff1
diff --git a/rust/crates/rusty-claude-cli/src/main.rs b/rust/crates/rusty-claude-cli/src/main.rs
index 41cdf194..722c3588 100644
--- a/rust/crates/rusty-claude-cli/src/main.rs
+++ b/rust/crates/rusty-claude-cli/src/main.rs
@@ -6971,8 +6971,23 @@ fn print_sandbox_status_snapshot(
}
fn sandbox_json_value(status: &runtime::SandboxStatus) -> serde_json::Value {
+ // Derive top-level status so automation can do a single field check
+ // instead of combining enabled/active/supported booleans.
+ // ok = not enabled (not requested), OR enabled and active
+ // warn = enabled and supported but not yet active (degraded)
+ // error = enabled but unsupported on this platform
+ let top_status = if !status.enabled {
+ "ok"
+ } else if status.active {
+ "ok"
+ } else if status.supported {
+ "warn"
+ } else {
+ "error"
+ };
json!({
"kind": "sandbox",
+ "status": top_status,
"enabled": status.enabled,
"active": status.active,
"supported": status.supported,