mirror of
https://github.com/ubiquitarianism/leonida.git
synced 2026-11-26 23:00:52 +01:00
[PR #1582] wave64_graphics_scan: harden --out guards, OSError privacy, atomic JSON, and tie-breaking (WAVE64-GRAPHICS-SCAN-CLI-AND-IO) #1602
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#1602
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/1582
Author: @IlyassRS3
Created: 11/25/2026
Status: 🔄 Open
Base:
main← Head:fix/wave64-graphics-scan-cli-and-io📝 Commits (1)
7817a45wave64_graphics_scan: harden --out guards, OSError privacy, atomic JSON, and tie-breaking📊 Changes
2 files changed (+171 additions, -8 deletions)
View changed files
📝
tests/test_wave64_graphics_scan.py(+105 -0)📝
tools/wave64_graphics_scan.py(+66 -8)📄 Description
Item:
WAVE64-GRAPHICS-SCAN-CLI-AND-IO(unclaimed — coordination issue #14 is at GitHub's 2,500-comment cap with no successor open issue yet, and 0 open PRs touchtools/wave64_graphics_scan.py).Summary
--outvalues instead of silently skipping--out ""or creating a whitespace-named file for--out " ", and validate the resolved symlink target's parent directory before scanning.OSErrorwhen enumerating/reading shader listings or writing--outand exit cleanly with code 2, stripping scanned shader filenames from error details so names stay inside the work folder.--outJSON atomically viafile_mode.published_mode+replace_retry.replacewithallow_nan=Falseand a trailing\nbefore printing stdout, preserving any existing report on write failure and leaving non-regular targets (e.g./dev/null) intact.(-count, op)) inoccurrencesandmask_word_sourcefor deterministic JSON and console output.Verification
python3 -W error -I tests/test_wave64_graphics_scan.py -v: 24/24 passed.python3 -I tests/test_text_write_line_endings.py: 3/3 passed.python3 -I scripts/check_no_game_data.py tools/wave64_graphics_scan.py tests/test_wave64_graphics_scan.py: passed.python3 -m compileall -q tools/wave64_graphics_scan.py tests/test_wave64_graphics_scan.py: passed.main:tools/wave64_graphics_scan.py):failures=5, errors=3across all new assertions.AI-assisted: yes
GPUs tested: none (CPU-only Python tool; synthetic fixtures only, no game data)
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.