From 779675f87e261827ce5bbebe8f8fc61e3760e8ba Mon Sep 17 00:00:00 2001 From: Git Sagar Date: Wed, 9 Sep 2026 13:13:30 -0300 Subject: [PATCH] macOS soak harness: judge runs by the builder's completion line nix build --rebuild exits non-zero when the byte-wise different qcow2 does not match the previous output; that is not a failed install. Co-Authored-By: Claude Fable 5.1 Claude-Session: https://claude.ai/code/session_01XsESshRCoBoUVWV9qKURUF --- lib/images/macos/tools/soak.sh | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/lib/images/macos/tools/soak.sh b/lib/images/macos/tools/soak.sh index bdb1435..663e897 100755 --- a/lib/images/macos/tools/soak.sh +++ b/lib/images/macos/tools/soak.sh @@ -23,6 +23,9 @@ for i in $(seq 1 "$RUNS"); do boots=$(grep -c 'guest kernel boot' "$L" 2>/dev/null); resets=$(grep -c 'system_reset' "$L" 2>/dev/null) panics=$(grep -c 'kernel panic' "$L" 2>/dev/null); tries=$(grep -c 'startosinstall try' "$L" 2>/dev/null) note=$(grep -oE 'prepare too slow[^,]*|PE did not[^,]*|guest halted|powering down|timeout reached' "$L" 2>/dev/null | sort | uniq -c | tr '\n' ';' | tr -s ' ') - printf '%-4s %-8s %-9s %-6s %-7s %-7s %-6s %s\n' "$i" "$([ $rc -eq 0 ] && echo OK || echo FAIL)" "$(( (t1 - t0) / 60 ))" "$boots" "$resets" "$panics" "$tries" "$note" | tee -a "$OUT/summary.txt" + # --rebuild makes nix exit non-zero when the (byte-wise different) qcow2 does not + # match the earlier output; judge the run by the builder's own completion line + if grep -q "install complete" "$D/build.log"; then res=OK; else res=FAIL; fi + printf '%-4s %-8s %-9s %-6s %-7s %-7s %-6s %s\n' "$i" "$res" "$(( (t1 - t0) / 60 ))" "$boots" "$resets" "$panics" "$tries" "$note" | tee -a "$OUT/summary.txt" done echo "logs: $OUT"