forge
Explore
Log in

Don't you dare go Hollow

stream: a_real_aomenc_lossless_444_key_frame stops reporting green on a missing pin

Browse files at this commit

60459a516bc54162d1aa733e969d07c004a4e43fAhmet Kaan GümüşParent: 542c8fe
The gate's pinned fixture `fixtures/ll444-lossless-key.obu` does not exist:
not in git, not in the root `fixtures/` directory on this box, and no
script under scripts/ produces it -- the only recorded provenance is the
prose recipe in the gate's own skip message. Its `Err` arm was a bare
SKIP, so it finished in 0.05s (its siblings take seconds: it had decoded
nothing) and the suite reported green.

The root `fixtures/` directory is listed in `.gitignore:2`, so the pin
cannot be committed and cannot be regenerated by a fresh clone; every
`~/.cache/wt/*` worktree lacks it for the same reason. The arm is
therefore kept as a skip (deleting the gate or failing every box
outright is worse), but `EC_AV1_REQUIRE_AOMENC=1` now turns it into a
hard failure that names the missing path, the exact regeneration recipe
and the `EC_AV1_PIN_DIR` override, so a batch run cannot report green off
it. The skip line itself now says the gate decoded nothing and proves
nothing.

Tests only; no gate body below the arm is touched.
crates/ec-av1/src/stream.rsmodified+28 -8
@@ -6488,14 +6488,34 @@ pub(crate) mod tests {
6488 eprintln!("SKIP {NAME}: no ffmpeg");6488 eprintln!("SKIP {NAME}: no ffmpeg");
6489 return;6489 return;
6490 }6490 }
6491- let Ok(stream) = std::fs::read(pin_dir().join("ll444-lossless-key.obu")) else {6491+ // lane-av1skipfix: this arm used to be a bare SKIP, so on any box
6492- eprintln!(6492+ // without the pin (the root `fixtures/` directory is GITIGNORED --
6493- "SKIP {NAME}: no pinned bytes at {} -- regenerate with \6493+ // `.gitignore:2` -- so a fresh clone can never have it) the gate
6494- `testsrc2 128x96` yuv444p 6 frames, aomenc --profile=1 --lossless=1 \6494+ // reported green having decoded nothing. `EC_AV1_REQUIRE_AOMENC=1`
6495- --enable-palette=0 --enable-intrabc=0, cut to the key frame's OBUs",6495+ // turns it into a hard failure naming the missing pin and its exact
6496- pin_dir().join("ll444-lossless-key.obu").display()6496+ // regeneration recipe, so a batch run cannot report green off it.
6497- );6497+ let pin = pin_dir().join("ll444-lossless-key.obu");
6498- return;6498+ let stream = match std::fs::read(&pin) {
6499+ Ok(stream) => stream,
6500+ Err(e) => {
6501+ assert!(
6502+ std::env::var_os("EC_AV1_REQUIRE_AOMENC").is_none(),
6503+ "{NAME}: the pinned 4:4:4 lossless key frame is missing at {} ({e}). \
6504+ Regenerate it with `testsrc2 128x96` yuv444p 6 frames, aomenc \
6505+ --profile=1 --lossless=1 --enable-palette=0 --enable-intrabc=0, \
6506+ cut to the key frame's OBUs -- or point EC_AV1_PIN_DIR at a \
6507+ directory that has it.",
6508+ pin.display()
6509+ );
6510+ eprintln!(
6511+ "SKIP {NAME}: no pinned bytes at {} ({e}) -- this gate decoded nothing \
6512+ and proves nothing; regenerate with `testsrc2 128x96` yuv444p 6 \
6513+ frames, aomenc --profile=1 --lossless=1 --enable-palette=0 \
6514+ --enable-intrabc=0, cut to the key frame's OBUs",
6515+ pin.display()
6516+ );
6517+ return;
6518+ }
6499 };6519 };
6500 // Blindness guard: the pinned fixture must really be a lossless frame.6520 // Blindness guard: the pinned fixture must really be a lossless frame.
6501 let mut parser = Av1Parser::new();6521 let mut parser = Av1Parser::new();