mirror of
https://github.com/ubiquitarianism/leonida.git
synced 2026-11-27 00:45:53 +01:00
[PR #1672] fma_mix_literal_probe: harden CLI parsing, hw oracle validation, and word masking #1686
Labels
No labels
bug
pull-request
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
starred/leonida#1686
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
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?
📋 Pull Request Information
Original PR: https://github.com/ubiquitarianism/leonida/pull/1672
Author: @IlyassRS3
Created: 11/25/2026
Status: 🔄 Open
Base:
main← Head:fix/fma-mix-literal-probe-cli-and-oracle📝 Commits (1)
c129c53fma_mix_literal_probe: harden CLI parsing, hw oracle validation, and word masking📊 Changes
2 files changed (+90 additions, -2 deletions)
View changed files
📝
tests/test_fma_mix_literal_probe.py(+65 -0)📝
tools/fma_mix_literal_probe.py(+25 -2)📄 Description
Item ID:
FMA-MIX-LITERAL-PROBE-CLI-AND-ORACLE(claimed in https://github.com/ubiquitarianism/leonida/issues/1608#issuecomment-7156151636)Summary
Unavailablehandling (tools/fma_mix_literal_probe.py):run_hw(), validate thatoracle.run()returns alist/tuplematchinglen(cases)and that every non-string entry is a non-emptylist/tuplewhose first element is anint(notbool), raisingRuntimeError(exit2) instead of silently truncating viazip()or crashing with uncaughtIndexError/TypeError.runner.Unavailableinside therun_hw()try/finallyblock inmain()soModeUnavailableduringoracle.run()exits77cleanly while closing the oracle.--hw-archand empty/trailing-comma--oracletokens ("","hw,",",translator") with argparse exit code2.word &= 0xFFFFFFFFinverdict()before exact 32-bit comparison.tests/test_fma_mix_literal_probe.py):Unavailableduringrun()+ oracle closure, and 32-bit word masking inverdict().Checklist & Verification
python3 -I scripts/check_no_game_data.py tools/fma_mix_literal_probe.py tests/test_fma_mix_literal_probe.pypassed)python3 -W error -I tests/test_fma_mix_literal_probe.py -v:Ran 10 tests ... OKtests/test_fma_mix_literal_probe.pyagainst unpatchedmaintools/fma_mix_literal_probe.py):Ran 10 tests ... FAILED (failures=9, errors=3)python3 -m compileall -q make_game.py tools tests: passedpython3 -I tests/test_text_write_line_endings.py:Ran 3 tests ... OK🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.