diff --git a/compute_tools/src/monitor.rs b/compute_tools/src/monitor.rs index 1588f5d62e..c871422e78 100644 --- a/compute_tools/src/monitor.rs +++ b/compute_tools/src/monitor.rs @@ -52,10 +52,16 @@ fn watch_compute_activity(compute: &ComputeNode) { let mut idle_backs: Vec> = vec![]; for b in backs.into_iter() { - let state: String = b.get("state"); - let change: String = b.get("state_change"); + let state: String = match b.try_get("state") { + Ok(state) => state, + Err(_) => continue, + }; if state == "idle" { + let change: String = match b.try_get("state_change") { + Ok(state_change) => state_change, + Err(_) => continue, + }; let change = DateTime::parse_from_rfc3339(&change); match change { Ok(t) => idle_backs.push(t.with_timezone(&Utc)),