forge
Explore
Log in

Don't you dare go Hollow

gen-fixture-library: stop injecting absent-pin rows for pins no code references

Browse files at this commit

fc5489f95f6f24aab016169d0d648164e9b80fe3Ahmet Kaan GümüşParent: 60e2653
Pass 1 already emits a row for every literal, including referenced-but-absent
pins, so the post-loop injection only ever fired for a path nothing reaches --
a deleted reference, not a library gap. Injecting it kept a stale claim alive
(ll444-lossless-key.obu was recovered under crates/ec-av1/fixtures/ and the
injected root row outlived the reference).
scripts/gen-fixture-library.shmodified+6 -6
@@ -214,12 +214,12 @@ while IFS= read -r pin; do
214 done < <(find "$ROOT"/crates/*/fixtures -maxdepth 1 -type f 2>/dev/null |214 done < <(find "$ROOT"/crates/*/fixtures -maxdepth 1 -type f 2>/dev/null |
215 sed "s#^$ROOT/##" | sort)215 sed "s#^$ROOT/##" | sort)
216 216
217-# Known-absent pins that no source literal reached still belong in the217+# A known-absent pin is annotated where a source literal actually REACHES for
218-# manifest: a missing pin must be a row, not a gap.218+# it (pass 1, above: `absent_pin` supplies the provenance and the `absent-pin`
219-for p in fixtures/ll444-lossless-key.obu fixtures/golden3-pin.obu fixtures/sbpart-pin.obu; do219+# status). Nothing is injected here: a pin no code references any more is not
220- grep -qP "^\Q$p\E\t" "$tmp" && continue220+# a gap in the library, it is a deleted reference, and inventing a row for it
221- row "$p" "(named absent pin)" "$(absent_pin "$p")" absent-pin >>"$tmp"221+# would keep a stale claim alive. A pin that IS referenced and IS absent still
222-done222+# gets a row, because pass 1 emits one for every literal.
223 223
224 # Which tests consume the fetched vector sets, and does anything need the224 # Which tests consume the fetched vector sets, and does anything need the
225 # .tar.gz blobs? The fleet sync excluded them deliberately, so a test that225 # .tar.gz blobs? The fleet sync excluded them deliberately, so a test that