refactor: harden diagnostics and consolidate runtime code

This commit is contained in:
Mikhail Chusavitin
2026-09-01 13:01:28 +03:00
parent ac4bc0b2b7
commit 0a6ca8ba0f
49 changed files with 1441 additions and 837 deletions
+11 -2
View File
@@ -454,10 +454,19 @@ func satFailureDetailFromKV(kv map[string]string) string {
continue
}
job := strings.TrimSuffix(k, "_status")
detail := strings.TrimSpace(kv[job+"_detail"])
if rc, ok := kv[job+"_rc"]; ok && strings.TrimSpace(rc) != "" {
failed = append(failed, fmt.Sprintf("%s=%s (rc=%s)", job, v, rc))
entry := fmt.Sprintf("%s=%s (rc=%s)", job, v, rc)
if detail != "" {
entry += ": " + detail
}
failed = append(failed, entry)
} else {
failed = append(failed, fmt.Sprintf("%s=%s", job, v))
entry := fmt.Sprintf("%s=%s", job, v)
if detail != "" {
entry += ": " + detail
}
failed = append(failed, entry)
}
}
if len(failed) == 0 {