Two bugs in agent-smoke.sh caused non-deterministic CI failures:
1. SIGPIPE race with pipefail: `printf | grep -q` fails when grep closes
the pipe early after finding a match, causing printf to get SIGPIPE
(exit 141). With pipefail, the pipeline returns non-zero even though
grep succeeded — producing false "undef" failures. Fixed by using
here-strings (<<<) instead of pipes for all grep checks.
2. Incomplete LIB_FUNS: hand-maintained REQUIRED_LIBS list (11 files)
didn't cover all 26 lib/*.sh files, silently producing a partial
function list. Fixed by enumerating all lib/*.sh in stable
lexicographic order (LC_ALL=C sort), excluding only standalone
scripts (ci-debug.sh, parse-deps.sh).
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>