tools: hash files without hashlib.file_digest so the checks run on Python 3.10 #366
Loading…
Reference in a new issue
No description provided.
Delete branch "upstream-pr/366"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Imported from brcly/TuxBox. Originally posted by snoozedDev on 2026-11-28T04:03:19Z.
Summary
CONTRIBUTING asks for Python 3.10 or newer, but
tools/check_d3d12_regressions.pyandtools/check_frame_profile.pycallhashlib.file_digest, which was added in Python 3.11. On 3.10 the D3D12 regression controls build everything and then stop withAttributeError: module 'hashlib' has no attribute 'file_digest'. The Python suite fails the same way: 2 errors intest_d3d12_regressions. CI runs only 3.12, so it never sees this.check_d3d12_regressions.pynow usesproject_tuxbox.inspect.digest, the streamed SHA-256 helper the launcher already uses in nine modules. Its localsha()is removed.check_frame_profile.pydoes not import the launcher package, so it streams intohashlib.sha256itself.digest,hashlib.file_digestandsha256sumagree.tests/test_frame_profile.py, checks thatcheck_frame_profile.inspectrefuses an executable whose hash doesn't match. On 3.10 without this change it fails with the sameAttributeError.fail-fast: false. The Rust job is unchanged. CONTRIBUTING now says CI uses both versions.tools/reference/xg-proxy/prepare.pyhas the same call. I left it alone becausetools/reference/is part of the audit in #359.Tested
Run the checks relevant to this change.
check --no-gpuand the Python suite on 3.10 and 3.12. The D3D12 regression controls were not run: this machine doesn't have the Windowsdxcompiler.dll/dxil.dllthey need. The only change in that tool is the function that computes the artifact fingerprints. The control logic is the same.GPU, driver and backend: none used.
Commands run and their results:
Checks
No evidence JSON changed.
AI use: This contribution was written by an AI agent (Claude Opus 5.5) operating under my supervision. I am accountable for it and will respond to review.