Repository navigation
Conversation
Grimkeh
left a comment
There was a problem hiding this comment.
Independent Linux CPU review
What changed: gamedata_reader excludes rejected XML from summary counters.
Checked: tests/test_gamedata_reader.py — 23 passed.
Looks correct; no game files.
|
Tested
Behavioural, not an Independent check (not the author). Run by an AI agent (DeepSeek V4.1 Flash) and re-run by the orchestrating session (Claude Code) before posting. |
|
Independent Windows CPython 3.12.10 integration check: current main867d922f + #7512 depth-failure handling + #9207's counter patch has one shared except-hunk conflict. Resolving it by keeping RecursionError in the exception tuple and retaining #9207's pre-document snapshots/clear+update rollback preserves both fixes. The combined reader suite passes all26 tests under ResourceWarning=error. An additional real-XML batch (valid, deeply nested typed XML, invalid vector array, malformed XML, valid) accepts2/rejects3, exports exactly the two correct valid values, has element/type counters identical to a valid-only run, and preserves the original Counter objects. No GPU or game files. This also closes the partial-count nit identified on #7512. Whichever PR lands second needs that one-hunk resolution; the integration-only commit is local and neither author's source branch was overwritten. AI-assisted. |
Summary
Streaming XML conversion can count fields before a later parse or conversion error rejects the document. Restore the pre-document element and type counters on that rejection path so the summary describes the accepted documents. Preserve the rejection counts and the original counter objects.
Claimed on the coordination issue.
Verification
On
main@867d922, the new fixture failed because both rejected documents affected the totals. After the fix, it passes for malformed XML and an invalid array, with successful documents on either side.python -B -m pytest -q -p no:cacheprovider tests/test_gamedata_reader.py tests/test_gamedata_xml.py tests/test_gamedata_index.pyon Windows 11: 68 passed, 1 skipped, 77 subtests passed.Read-only spot check of one local archive, 267 XML groups: 259 accepted and 8 rejected. Counts matched the sum of the accepted documents alone. A document modified only in memory to fail late increased only the rejection counts.
python -B -I scripts/check_no_game_data.pyandgit diff --checkpassed. The current gamedata_reader: convert scalars, vectors and number arrays 1.5-2.9x faster, same values #7706 patch also passedgit apply --checkover the changed worktree.The broader semantic run reported 5,957 tests across 447 files. Its only two failing files,
test_image_atomics_guardandtest_image_store_d16, also failed when rerun on the clean base commit.AI-assisted (Codex).