Skip to content

armgit / Pulse

Public Imported from GitHub
0

Real-time monitoring dashboard for Proxmox VE, PBS, Docker, Kubernetes, TrueNAS and vSphere. Self-hosted, with alerts for failed backups, full disks, unhealthy containers and offline nodes.

Retain confined native-harness failure diagnostics

pulse-triage[bot]2c2a298e1c4d
diff --git a/scripts/installtests/auto_update_systemd.py b/scripts/installtests/auto_update_systemd.py
index 8134a4e414..39777c8ed5 100644
--- a/scripts/installtests/auto_update_systemd.py
+++ b/scripts/installtests/auto_update_systemd.py
@@ -159,6 +159,8 @@ class NativeLab:
"deadline_exceeded": True,
"observed_exit": process.returncode}
raise RuntimeError("native command deadline exceeded") from None
+ # Private in-memory diagnostic for confined controls, never a receipt field.
+ self._last_output = output
result = subprocess.CompletedProcess(args, process.returncode, output)
if result.returncode not in ok:
self.receipt["command_failure"] = {"command": Path(args[0]).name,
diff --git a/scripts/tests/test_auto_update_systemd.py b/scripts/tests/test_auto_update_systemd.py
index 7d38aa9d19..77fb1e2d6c 100644
--- a/scripts/tests/test_auto_update_systemd.py
+++ b/scripts/tests/test_auto_update_systemd.py
@@ -266,8 +266,11 @@ else:
return original_write(path, data, *args, **kwargs)
try:
with patch.object(Path, "write_text", new=relocate), patch.object(native.time, "sleep"):
- lab.prepare()
- lab.exercise()
+ try:
+ lab.prepare()
+ lab.exercise()
+ except RuntimeError as error:
+ self.fail(str(error) + "\nConfined fixture output:\n" + lab._last_output.decode())
self.assertEqual([p["name"] for p in lab.receipt["phases"]],
["forward", "manual-reverse", "failed-active", "failed-inactive",
"failed-masked", "bad-signature", "incomplete-restore"])