From d9972db407cb83d6cf2078ba7ab5ebc6c1a9bbf1 Mon Sep 17 00:00:00 2001 From: Miguel Angel Simon Sierra Date: Sat, 19 Sep 2026 05:33:12 -0400 Subject: [PATCH] fix(scripts): the capture checker exits 2 when it cannot check A bad option, a missing binary or file, or an undecodable video used to read as clean or crash with exit 1, which the caller cannot tell from a flagged capture. Options are now validated, the frame height is passed to ffmpeg explicitly so it always matches the size the check assumes, and the tests pin the thresholds, window boundary, ordering and mean. --- CONTRIBUTING.md | 2 +- scripts/check-capture-reversion.mjs | 74 +++++++++++++++--------- scripts/check-capture-reversion.test.mjs | 48 ++++++++++++++- 3 files changed, 95 insertions(+), 29 deletions(-) diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 53ed8631ba..69d8752311 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -149,7 +149,7 @@ The script wipes `docs/catalog/` before regenerating, so deleted items are autom ### Checking a capture -A screen recording attached to a PR must not show a region briefly returning to an older picture (a clip that reappears for one frame, a panel that flashes its previous state). Run `node scripts/check-capture-reversion.mjs [--crop=W:H:X:Y]