From 48b48a8481f3f7db38ebd9d993315cf9395a8fbd Mon Sep 17 00:00:00 2001 From: Vitor Pamplona Date: Fri, 8 May 2026 10:59:42 -0400 Subject: [PATCH] fix(quic-interop): summarize-matrix picks newest run dir, not sibling .stdout.log MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit `ls -1dt run-*` returns both the per-run directories AND the `.stdout.log` files run-matrix.sh tees alongside them, interleaved by mtime. `head -n 1` could land on a `.stdout.log` regular file, after which the rest of the script trying to walk subdirectories under it silently produced empty output ("no dir under …"). Walk the listing instead and pick the first entry that is actually a directory. Co-Authored-By: Claude Opus 4.7 (1M context) --- quic/interop/summarize-matrix.sh | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/quic/interop/summarize-matrix.sh b/quic/interop/summarize-matrix.sh index 56a7b901a..deb65f03a 100755 --- a/quic/interop/summarize-matrix.sh +++ b/quic/interop/summarize-matrix.sh @@ -16,7 +16,13 @@ if [[ ! -d "$RUNNER_LOGS" ]]; then exit 1 fi -RUN_DIR="$(ls -1dt "$RUNNER_LOGS"/run-* 2>/dev/null | head -n 1 || true)" +RUN_DIR="" +while IFS= read -r candidate; do + if [[ -d "$candidate" ]]; then + RUN_DIR="$candidate" + break + fi +done < <(ls -1dt "$RUNNER_LOGS"/run-* 2>/dev/null) if [[ -z "$RUN_DIR" ]]; then echo "no run-* dirs under $RUNNER_LOGS" >&2 exit 1