tooling: report disasm_rdna2 CLI input errors and honor --output with --hex #1975
Loading…
Reference in a new issue
No description provided.
Delete branch "upstream-pr/1982"
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 R0Y00/Xbox2Windows. Originally posted by RenzoWit35 on 2026-11-24T22:36:42Z.
Change
In
tools/disasm_rdna2.pymain():--hexnow adds its listing to the shared--outputwriter (previously it returned before it, so the file was never written).--hexvalue now ends inparser.error(exit 2, one line) instead of aValueErrortraceback.error: <path>: not foundto stderr and the tool exits 1 after processing the other targets (previously exit 0, no output).Stdout of successful runs is unchanged. A regression case sits next to
test_cli_hex_entry_point.Verification
Environment: Windows 11, Python 3.14.5.
python -B tests/rdna2_tools_check.pyafter the change: Ran 153 tests, OK (skipped=19).tools/disasm_rdna2.py:test_cli_hex_output_and_input_errorsERROR, Ran 153, FAILED (errors=1, skipped=19).--hex 000080bfstdout hash identical before and after.Not run: the rest of the suite, CMake.
Evidence and follow-up
Rebased on current
main. No open PR touchestools/disasm_rdna2.py. The sibling PRs for VOPC DPP and the SMEM signed offset change other parts of the same two files; the three merge in any order.AI-assisted.
Imported from R0Y00/Xbox2Windows. Originally posted by tedin7 on 2026-11-24T22:45:27Z.
Review: COMMENTED
Review of head
20fa94a9b2(2 files: tools/disasm_rdna2.py, tests/rdna2_tools_check.py; no CMake changes, clean-room OK).Semantics:
--hexnow reports bad input throughparser.error(exit 2, no traceback),--outputis honored together with--hex, and missing targets printerror: <path>: not foundand exit 1. Behavior is correct and the test covers all three paths.Commands executed locally:
python3 -B tests/rdna2_tools_check.py: OK (153 tests, 19 skipped)python3 tests/docs_links_check.py: PASSpython3 tests/bidi_controls_check.py: PASSgit diff --check origin/main...HEAD: cleangit merge-tree --write-tree --name-only origin/main HEAD: no conflictspython3 x2w_pipe.py win2025 1982 --wait 900: Debug 18/18 and Release /O2 18/18 passedreturn 1 if missing else 0->return 0: test_cli_hex_output_and_input_errors FAILED (killed)--outputwrite block : test FAILED (killed)P1: 0. P2: 0.
AI-assisted; commands listed were executed locally.