Skip to content

Self-hosted, Self-Improving, Federated Everything App — dev management, agent orchestration, persistent mind, digital twin, second brain, and creative pipeline from a single dashboard over Tailscale to port the user into the OS

address review (ollama): guard the sudo probe so telemetry never crashes training

[._.]/ Adam Eivy1936c1431a04
diff --git a/scripts/train_mflux_lora.py b/scripts/train_mflux_lora.py
index adda663ef9..c68a607716 100644
--- a/scripts/train_mflux_lora.py
+++ b/scripts/train_mflux_lora.py
@@ -225,7 +225,12 @@ class TelemetrySidecar:
# /usr/bin/true) would fail for exactly the users who configured it
# correctly. `sudo -n -l <cmd>` lists the permission without running
# powermetrics and without prompting; non-zero means not allowed.
- probe = subprocess.run(["sudo", "-n", "-l", pm], capture_output=True)
+ # Telemetry is best-effort — a missing `sudo` must never crash training.
+ try:
+ probe = subprocess.run(["sudo", "-n", "-l", pm], capture_output=True)
+ except OSError as err:
+ log(f"STATUS:GPU telemetry unavailable ({err}); continuing without it")
+ return
if probe.returncode != 0:
log("STATUS:GPU telemetry disabled — passwordless sudo for powermetrics not configured; "
"see docs/TROUBLESHOOTING.md to enable thermal/power capture. Continuing without it.")