Repository navigation
fix(cli): keep check --json stdout pure by sending proxy pre-resolve diagnostics to stderr - #3836
Merged
Merged
Conversation
miga-heygen
enabled auto-merge (squash)
September 10, 2026 02:30
miga-heygen
force-pushed
the
fix/check-json-proxy-preresolve-stderr
branch
from
September 10, 2026 02:31
a8ea8d0 to
8da0950
Compare
miguel-heygen
force-pushed
the
fix/check-json-proxy-preresolve-stderr
branch
from
October 2, 2026 10:31
8da0950 to
b5644d1
Compare
Edit accuracy: accurate 1216 (base branch 1216), smooth 1009 of thoseThe gate passes. Quarantined, measured but not gated (1)
|
…diagnostics to stderr preResolveHostileMediaProxies() logged its summary and scan-failure lines via console.info, which writes to stdout. With autoProxy on (the default), any project containing HEVC/ProRes/AV1 media emitted that line ahead of the JSON envelope from `check --json`, so JSON.parse(stdout) failed for consumers of the machine-readable output. Route both diagnostics through console.error (stderr), matching how the check command already reports its own failures. Add regression tests asserting the summary and scan-failure lines land on stderr and that stdout stays untouched.
miguel-heygen
force-pushed
the
fix/check-json-proxy-preresolve-stderr
branch
from
October 2, 2026 12:08
a197335 to
7ce2be3
Compare
5 tasks done
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
hyperframes check --jsondid not always print pure JSON on stdout.preResolveHostileMediaProxies()inpackages/cli/src/utils/checkBrowser.tslogged its summary line ([hyperframes] media proxy pre-resolve: N/M ready, F failed (Xms)) and its scan-failure line withconsole.info, which writes to stdout. With auto-proxy on (the default), any project with HEVC/ProRes/AV1 media printed that line before the JSON envelope, soJSON.parse(stdout)failed for machine consumers.Fix
Both lines now go through
console.error(stderr). This is the function's only caller path and its only stdout writes, so one change covers every case. In human mode the line still shows in the terminal, but it now goes to stderr: a run that captures only stdout (hyperframes check > log) no longer records it. Nothing in the repo parses it, and exit codes and the JSON shape are unchanged.Size
Under 100 lines: two
console.infotoconsole.errorswaps plus tests.Tests
console.error.N/M ready, F failed (Xms)shape;console.info,console.logandprocess.stdout.writeare never called.vitest run src/utils/checkBrowser.test.ts: 18/18 pass; with the swap reverted, the 3 stderr tests fail (15/18).tsc --noEmit -p packages/cliandoxfmt --checkclean.