The agent that grows with you
Python aiai-agentai-agentsanthropicchatgptclaudeclaude-codecodexhermeshermes-agentllmnous-researchopenai
refactor(process-identity): narrow the boot-start probes for the health ratchet
Tekniumb5b74e4ff254
diff --git a/hermes_cli/process_identity.py b/hermes_cli/process_identity.pyindex 3f009315189..6a25f62d2a5 100644--- a/hermes_cli/process_identity.py+++ b/hermes_cli/process_identity.py@@ -135,19 +135,16 @@ def _verified_boot_start(pid: Optional[int], create_time: Optional[float]) -> Opproc = psutil.Process(pid)return boot_start(proc) if _same_incarnation(proc, create_time) else None- except Exception:+ except Exception: # health: allow BLE001 -- best-effort probe like _process_create_time: any failure is "unproven"return Nonedef _step_can_explain_mismatch(pid: int, boot: Optional[float]) -> bool:"""A live ``pid`` failed an epoch-only match on Linux: a clock step explains that as well as areused pid, so the mismatch proves nothing. ``False`` when ``boot`` was recorded (exact)."""- try:- import psutil+ import psutil # the caller's epoch match already needed it- return boot is None and getattr(psutil, "LINUX", False) and psutil.pid_exists(pid)- except Exception:- return False+ return boot is None and bool(getattr(psutil, "LINUX", False)) and psutil.pid_exists(pid)# Layer 1 — spawn tags