Repository navigation
fix(tools): validate First Light manifest coverage bounds (Codex) - #5843
evilclanker9000 wants to merge 1 commit into
Conversation
|
AI-assisted Windows CPU compatibility check with uv CPython 3.12.13. #5843 With a stock-style mocked 2×2 RGBA readback, |
|
Tested
AI-assisted. |
|
Tested 88c1a51 merged with main 561b65a on Linux (WSL2) Python 3.12.16: pass tests/test_first_light.py: 48 run, 44 passed, 0 failed, 4 skipped (the same 4 skips occur with the upstream/main tools file). Negative control: restoring tools/first_light.py from upstream/main (keeping the PR's test) gives 48 run, 8 failures + 4 errors, all in test_coverage_bounds_must_be_finite_numbers subtests (nan, +/-inf and True accepted silently; None and "0.5" raise a TypeError instead of the AssertionError). With the PR's change all subtests pass. File restored afterwards. |
Claimed in the coordination issue as: EGEN-FIRST-LIGHT-FINITE-COVERAGE-BOUNDS
Depends on: #3751 (its existing First Light merge conflicts still need resolution)
What and why
Reject non-finite and nonnumeric coverage bounds in saved First Light manifests. A bound that cannot represent a numeric threshold can either admit an invalid frame or raise a Python error. Name the invalid field and preserve inclusive comparisons and the defaults for omitted bounds.
Tested
88c1a51a. The targeted regression on main produced eight failed assertions and four type errors from the invalid-bound matrix. Both regression methods passed with the fix.python3 -I tests/test_first_light.py OracleTests TexturedOracleTests: 17 passed, one skipped.AI-assisted: yes
Checklist