wave32_pixel_scan: use shared same_report_path and catch --out write OSError (DRAFT-301) #932

Open
github-bot wants to merge 1 commit from github-bot/gh-932 into main AGit
Owner

@⁠fin-github on GitHub · 2026-11-24 15:17 UTC · original
fin-github:draft/301 → main · +61 −3 · 2 files · 1 commits · open

Claimed in the coordination issue as: DRAFT-301 (#14)

Supersedes draft #301, carried over from the original repository. This is the same commit rebased onto current main, with the original author (EspadaHD) kept and git cherry-pick -x recording where it came from. The change and its explanation are theirs; see #301 for the original description.

Tested

  • python -I tests/test_wave32_pixel_scan.py: OK
  • python -I scripts/check_no_game_data.py on the changed files: clean.

Windows 11 (10.0.26200), Python 3.14.4. No game files, nothing online.

AI-assisted (Claude Code): rebasing, conflict resolution and test runs.

**@⁠fin-github** on GitHub · 2026-11-24 15:17 UTC · [original](https://github.com/ubiquitarianism/leonida/pull/932) `fin-github:draft/301` → `main` · +61 −3 · 2 files · 1 commits · open Claimed in the coordination issue as: `DRAFT-301` (https://git.gtahub.st/github/ubiquitarianism--leonida/issues/14) Supersedes draft #301, carried over from the original repository. This is the same commit rebased onto current `main`, with the original author (EspadaHD) kept and `git cherry-pick -x` recording where it came from. The change and its explanation are theirs; see #301 for the original description. ### Tested - `python -I tests/test_wave32_pixel_scan.py`: OK - `python -I scripts/check_no_game_data.py` on the changed files: clean. Windows 11 (10.0.26200), Python 3.14.4. No game files, nothing online. AI-assisted (Claude Code): rebasing, conflict resolution and test runs.
github-bot locked as GitHub sync and limited conversation to collaborators 2026-11-26 09:28:57 +00:00
Author
Owner

@⁠PierreEbele on GitHub · 2026-11-25 21:37 UTC · original

Reviewed d1dc202: wave32_pixel_scan refuses a --out that names a scanned listing through any spelling and reports a failed report write with exit 2 instead of a traceback; two tests added. I ran tests/test_wave32_pixel_scan.py (15/15 on the PR; both new tests error on main) and a CLI probe with a hand-built disasm: the write-failure fix and the listing-alias refusal behave as intended. Finding: the scan also reads the carve index.json (stage_of) and fssm/<name>.fssm (wave size), but the new guard protects only the listings - --out <root>/index.json and --out <root>/fssm/ps_lane.fssm still exit 0 and overwrite those inputs, here and on main, while wave64_graphics_scan refuses the same invocations (metadata_paths). Suggest extending the guard to those inputs in this PR. Measured guard cost: ~0.75s over 20k listings, same profile as the merged wave64 guard. AI-assisted review.

Recommendation: Fix first

**@⁠PierreEbele** on GitHub · 2026-11-25 21:37 UTC · [original](https://github.com/ubiquitarianism/leonida/pull/932#issuecomment-7175335985) Reviewed d1dc202: wave32_pixel_scan refuses a `--out` that names a scanned listing through any spelling and reports a failed report write with exit 2 instead of a traceback; two tests added. I ran `tests/test_wave32_pixel_scan.py` (15/15 on the PR; both new tests error on main) and a CLI probe with a hand-built disasm: the write-failure fix and the listing-alias refusal behave as intended. Finding: the scan also reads the carve `index.json` (stage_of) and `fssm/<name>.fssm` (wave size), but the new guard protects only the listings - `--out <root>/index.json` and `--out <root>/fssm/ps_lane.fssm` still exit 0 and overwrite those inputs, here and on main, while wave64_graphics_scan refuses the same invocations (metadata_paths). Suggest extending the guard to those inputs in this PR. Measured guard cost: ~0.75s over 20k listings, same profile as the merged wave64 guard. AI-assisted review. **Recommendation:** Fix first
This pull request can be merged automatically.
This branch is out-of-date with the base branch
You are not authorized to merge this pull request.
View command line instructions

Checkout

From your project repository, check out a new branch and test the changes.
git fetch -u origin '+refs/pull/932/head:github-bot/gh-932'
git switch 'github-bot/gh-932'

Merge

Merge the changes and update on Forgejo.
git switch 'main'
git merge --no-ff 'github-bot/gh-932'
git switch 'github-bot/gh-932'
git rebase 'main'
git switch 'main'
git merge --ff-only 'github-bot/gh-932'
git switch 'github-bot/gh-932'
git rebase 'main'
git switch 'main'
git merge --no-ff 'github-bot/gh-932'
git switch 'main'
git merge --squash 'github-bot/gh-932'
git switch 'main'
git merge --ff-only 'github-bot/gh-932'
git switch 'main'
git merge 'github-bot/gh-932'
git push origin 'main'
This discussion has been locked. Commenting is limited to contributors.
No description provided.