Repository navigation
tools: read boot timeline states from the configured RVAs - #2186
ecox982745 wants to merge 1 commit into
Conversation
Use the game and session RVAs supplied to the boot script, with command-line overrides for saved logs. Ignore unrelated peek samples and report when a log has no matching fields. AI-assisted-by: OpenAI Codex (gpt-6.2-astra)
|
Verified on main a73a57e (Ubuntu 24.04 x86-64, Python 3.13, no GPU). Merges cleanly into main. With this PR, python -I tests/test_stage_timeline_rvas.py: 5 tests OK. The PR's test file against main's tools/stage_timeline.py: 5 failures, so the new tests fail on main and pass with the change. compileall clean. Overlap for review: #2232 (TOOL-STAGE-TIMELINE-TESTS, mine) also changes tools/stage_timeline.py and adds tests/test_stage_timeline.py. The two conflict in main(), and this PR changes read() to take the RVAs and makes the CLI require them, which #2232's tests do not pass yet. Whichever lands second needs a rebase; if this one lands first, I will rebase #2232 onto it and update its tests to the RVA arguments. AI-assisted: yes (Claude Code) |
Claimed in the coordination issue as TOOL-STAGE-TIMELINE-PEEK-RVAS. This follows aslan2142’s finding after #2138 merged.
What and why
The boot script now records locally configured state addresses. The offline timeline still looked up three fixed addresses. A log recorded with different addresses could report “no title state yet” throughout a run and pair presses with misleading transitions.
The timeline now uses
LEONIDA_GAME_STATE_RVAandLEONIDA_SESSION_STATE_RVA. Each can be overridden on the command line for saved logs.--load-state-rvaselects the optional loading-screen byte. Unrelated samples are skipped, and a log with no matching fields exits with a diagnostic. A matching unreadable field still represents an unknown state.Tested
0b11d86bcand passed on the proposed tree. It covers JSON and text output, press pairing, optional loading-state transitions, hexadecimal spellings, and configuration errors.0b11d86bcproduces the exact tested tree (6dc52c3dd). tools: harden stage_timeline.py parsing, OSError handling and stdout guard #1789 also edits this parser and its proposed tests assume fixed addresses. If that PR proceeds, those fixtures will need to supply their RVAs.GPUs tested: N/A for the offline log reader. Tests ran on Windows.
AI-assisted: OpenAI Codex (
gpt-6.2-astra).