fix(gate): residency-accept checks the example's seed rc — read 20/0 while seed SEGV'd

- scripts/residency-accept.sh:155 ran docs/examples/residency `seed` with its
  rc unchecked; the inserts commit before the crash, so the restart legs passed
  on the log a dead seed left behind and the gate read 20/0 while seed died 139
- new check "example: seed exits 0" — its FAIL names the rc (139 = SIGSEGV)
  and the log to read
- failing-first on today's binary: `FAIL example seed -- rc=139`; the SEGV is
  the pre-existing keys-resident fresh-log defect (wo_wal_fold_row_at, HEAD
  wal.c:1837), zack's fix in flight — this check stays red until it lands

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
(cherry picked from commit e274f4a932688bccf8310581199fa0d26f737eea)
This commit is contained in:
shoney.arickathil 2026-09-10 14:42:57 +02:00
parent ea66761c4e
commit 37c24e13bc

View file

@ -152,9 +152,14 @@ if "$WOC" --emit "$EX/main.wo" -o "$WORK/residency.wob" >>"$LOG" 2>&1; then
mkdir -p "$WORK/exdata"
{
echo "--------------------- run 1: seed ---------------------"
WO_DATA="$WORK/exdata" "$WOVM" "$WORK/residency.wob" seed 2>&1
WO_DATA="$WORK/exdata" "$WOVM" "$WORK/residency.wob" seed 2>&1; rc=$?
echo "--------------------- run 2: restart + order ----------"
} >> "$LOG"
# seed's rows commit before anything can crash it, so the restart legs
# below pass on the log a dead seed leaves behind — its rc is its own check
[[ $rc -eq 0 ]] \
&& ok "example: seed exits 0" \
|| bad "example seed" "rc=$rc (139 = SIGSEGV; see $LOG)"
ex2="$(WO_DATA="$WORK/exdata" "$WOVM" "$WORK/residency.wob" order 2>&1)"
printf '%s\n' "$ex2" >> "$LOG"
grep -q 'products=2 carts=0' <<<"$ex2" \