a73x

b3562f8e

test: the xos QUIC agent leg reads mux a's exit code on the box

a73x   2026-09-04 12:50

Commit message
test: the xos QUIC agent leg reads mux a's exit code on the box

One run ended the leg with an empty stdout, nothing on stderr and a
message that could not say what had exited how. Every verb failure in
muxa.zig prints JSON before it exits, so an empty capture is a death by
signal, and only the shell on the box knows which; it now says.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01SakwJEwD9dXBoRP5kWbemW

test/xos.sh
Old New
@@ -518,12 +518,27 @@ ok mac-to-linux "a macOS client typed into shell $M2L_PID under daemon $LPID on
518 # ---- leg 6: mac-to-linux-quic — no ssh anywhere in the path ------------ 518 # ---- leg 6: mac-to-linux-quic — no ssh anywhere in the path ------------
519 # The Darwin wolfSSL build's PSK handshake against the musl build's, in one 519 # The Darwin wolfSSL build's PSK handshake against the musl build's, in one
520 # round trip, joining the session leg 5 made. `mux a` never creates. 520 # round trip, joining the session leg 5 made. `mux a` never creates.
521 #
522 # The exit code is read on the box and stderr kept there, because a `mux a`
523 # that dies by signal writes its JSON to neither stream and the shell that
524 # ran it is the only witness. One run on 2026-09-04 ended this leg with an
525 # empty stdout, nothing on stderr and a message that could not say what had
526 # exited how; every verb failure in muxa.zig prints `{"error":...}` before
527 # it exits, so an empty capture is a death and the code says which signal.
521 leg 528 leg
522 AQ=$(box_ssh 120 "$MAC_BOX" <<M 529 AQ=$(box_ssh 120 "$MAC_BOX" <<M
523 MUX_KEY_FILE=\$HOME/xos/key \$HOME/.local/bin/mux a run --quic $LAN_IP:$QUIC_PORT \ 530 MUX_KEY_FILE=\$HOME/xos/key \$HOME/.local/bin/mux a run --quic $LAN_IP:$QUIC_PORT \
524 --key \$HOME/xos/key --timeout 20000 'echo m2lq-\$\$' 531 --key \$HOME/xos/key --timeout 20000 'echo m2lq-\$\$' 2>\$HOME/xos/aq.err
532 echo "AQRC=\$?"
533 M
534 ) || fail mac-to-linux-quic "$MAC_BOX would not run mux a: $AQ"
535 AQ_RC=$(printf '%s\n' "$AQ" | sed -n 's/^AQRC=//p')
536 [ "$AQ_RC" = 0 ] || {
537 echo "xos FAIL: mac-to-linux-quic: mux a run --quic exited ${AQ_RC:-with no code} on $MAC_BOX (past 128 is a signal: 141 SIGPIPE, 139 SIGSEGV) and said: $AQ"
538 box_ssh 60 "$MAC_BOX" <<'M' | sed 's/^/ /' || true
539 cat $HOME/xos/aq.err 2>/dev/null
525 M 540 M
526 ) || fail mac-to-linux-quic "mux a run --quic answered nothing from $MAC_BOX: $AQ" 541 exit 1; }
527 case "$AQ" in 542 case "$AQ" in
528 *'"mechanism":"marks"'*) ;; 543 *'"mechanism":"marks"'*) ;;
529 *) fail mac-to-linux-quic "no marks mechanism in the reply: $AQ" ;; 544 *) fail mac-to-linux-quic "no marks mechanism in the reply: $AQ" ;;