Environment: adk CLI 2.0.1 (linux-x64 release binary — bun-compiled single-file executable; stack traces show /$bunfs/root/adk-linux-x64); @botpress/evals 2.0.2; Ubuntu.
When the JSON report from adk evals --format json is large (judge-heavy suites: each llm_judge assertion embeds its full rubric; one of our group reports is ~144 KB), piping stdout truncates it mid-JSON at ~64–73 KB. Redirecting to a file is always complete.
adk evals --format json > report.json → complete, valid JSON, every time.
adk evals --format json | anything (e.g. | jq ., | tee, or a pipe into a gate script) → truncated at ~64–73 KB, unparseable.
- Small reports (a few KB) pipe fine — the size threshold is what you'd expect if the process exits before pending async pipe writes are flushed (pipes block at the kernel buffer boundary; regular-file writes are synchronous). This looks like the known bun footgun of
process.exit() racing pending stdout writes.
Expected: stdout is fully flushed before exit regardless of what stdout is attached to. --format json exists to be consumed programmatically, and the natural consumer shape is a pipe.
Repro:
- Any eval suite whose JSON report exceeds ~100 KB (many
llm_judge assertions is the easy way).
adk evals --format json > a.json vs adk evals --format json | cat > b.json.
a.json is complete; b.json is cut mid-JSON at ~64–73 KB (jq . b.json fails).
Observed 2026-07-10, reconfirmed since on adk 2.0.1.
Workaround: always redirect to a file and read the file.
Environment: adk CLI 2.0.1 (linux-x64 release binary — bun-compiled single-file executable; stack traces show
/$bunfs/root/adk-linux-x64);@botpress/evals2.0.2; Ubuntu.When the JSON report from
adk evals --format jsonis large (judge-heavy suites: eachllm_judgeassertion embeds its full rubric; one of our group reports is ~144 KB), piping stdout truncates it mid-JSON at ~64–73 KB. Redirecting to a file is always complete.adk evals --format json > report.json→ complete, valid JSON, every time.adk evals --format json | anything(e.g.| jq .,| tee, or a pipe into a gate script) → truncated at ~64–73 KB, unparseable.process.exit()racing pending stdout writes.Expected: stdout is fully flushed before exit regardless of what stdout is attached to.
--format jsonexists to be consumed programmatically, and the natural consumer shape is a pipe.Repro:
llm_judgeassertions is the easy way).adk evals --format json > a.jsonvsadk evals --format json | cat > b.json.a.jsonis complete;b.jsonis cut mid-JSON at ~64–73 KB (jq . b.jsonfails).Observed 2026-07-10, reconfirmed since on adk 2.0.1.
Workaround: always redirect to a file and read the file.