fix(quic-interop): inspect — skip non-dir matches of run-* glob
The 'run-<timestamp>.stdout.log' siblings also match the 'run-*' glob — zsh in particular returns them mixed with the actual run dirs. The for-loop now filters to directories only. (The summarize-matrix script was already OK — it does ls -1d followed by a head -1, and run dirs come first in mtime order.)
This commit is contained in:
@@ -20,12 +20,11 @@ RUNNER_LOGS="${REPO_ROOT}/../quic-interop-runner/logs"
|
||||
|
||||
# Most recent run dir that has the named testcase.
|
||||
RUN_DIR=""
|
||||
# Filter to actual directories — zsh's glob also matches the
|
||||
# sibling .stdout.log files that run-matrix.sh tees, which start
|
||||
# with the same 'run-' prefix and would resolve as not-a-dir.
|
||||
for d in $(ls -1dt "$RUNNER_LOGS"/run-* 2>/dev/null); do
|
||||
if [[ -d "$d"/*amethyst*/"$TC" ]] 2>/dev/null; then
|
||||
RUN_DIR="$d"
|
||||
break
|
||||
fi
|
||||
# Fallback for shells that don't expand the glob in the test:
|
||||
[[ -d "$d" ]] || continue
|
||||
if ls -d "$d"/*amethyst*/"$TC" >/dev/null 2>&1; then
|
||||
RUN_DIR="$d"
|
||||
break
|
||||
|
||||
Reference in New Issue
Block a user