Summary
landing/app/pods.py:239 calls datetime.fromisoformat(last_seen_raw) unguarded inside the per-pod loop of cleanup_idle_pods. If any single pod has a malformed or unparseable sus.dev/last-seen annotation, the exception aborts the entire cleanup pass — no idle pods get reaped that iteration.
The caller (cleanup.py:26-39) catches and logs it, so it's not fatal, but a persistently-bad annotation on one pod blocks reaping of all idle pods indefinitely, which defeats the reaper and can pile up abandoned pods.
Suggested fix
Wrap the per-pod timestamp parse in try/except; on failure, skip that pod (or treat it as stale) and continue the loop instead of letting one bad annotation kill the sweep.
Found during a repo audit.
Summary
landing/app/pods.py:239callsdatetime.fromisoformat(last_seen_raw)unguarded inside the per-pod loop ofcleanup_idle_pods. If any single pod has a malformed or unparseablesus.dev/last-seenannotation, the exception aborts the entire cleanup pass — no idle pods get reaped that iteration.The caller (
cleanup.py:26-39) catches and logs it, so it's not fatal, but a persistently-bad annotation on one pod blocks reaping of all idle pods indefinitely, which defeats the reaper and can pile up abandoned pods.Suggested fix
Wrap the per-pod timestamp parse in try/except; on failure, skip that pod (or treat it as stale) and continue the loop instead of letting one bad annotation kill the sweep.
Found during a repo audit.