Commit Graph

18 Commits

Author SHA1 Message Date
a554262ba8 Merge pull request #1136 from Taffyyy-ops/fix/audio-config-scan-search
audio_config: search sparse markers efficiently (AUDIO-CONFIG-SCAN-SEARCH)
2026-11-29 15:37:57 +01:00
fc4f6311a4 audio_config: scan individual configuration files in bounded chunks 2026-11-27 18:29:36 +08:00
92d90a0360 audio_config: search sparse markers efficiently (AUDIO-CONFIG-SCAN-SEARCH) 2026-11-24 20:06:48 +01:00
7761680eac audio_config: read the --names pool as latin-1 bytes, the hash joaat uses (EGEN-AUDIOCONFIG-POOL-LATIN1) (#6619)
Squash-merged after diff review of PR #6619
2026-11-23 11:14:15 -06:00
b33fa5b1cf audio_config: accept a record with exactly 20 trailing bytes (#6626)
Squash-merged after diff review of PR #6626
2026-11-23 11:12:48 -06:00
77247b699a docs: clarify AWC manifest duration units (#6854)
Squash-merged after diff review of PR #6854 - docs: clarify AWC manifest duration units
2026-11-23 09:49:10 -06:00
d1490e359e BUILD-1046: missing inputs exit 2; image_query_probe help before oracle
Eleven tools treated a nonexistent input folder as a failed run (1). They now print one ERROR line and return 2, while real read failures keep exit 1. image_query_probe imports the hardware oracle only for a GPU run, so --help stays prompt. A table-driven subprocess test covers all eleven; existing expectations are updated.
2026-11-22 21:11:07 +00:00
0a8c08a564 audio_config, world_names: hash a name as the pinned latin-1 joaat does
audio_config hashed the lowercased UTF-8 bytes, and world_names encoded to UTF-8
before lower-casing the bytes, so both gave a different 32-bit hash for any
non-ASCII name than hashdict.py and awc_names.py, which hash the lowercased
latin-1 bytes that tests/test_hashdict.py pins. A title with an accent then
produced a stream id no AWC bank stores. Both copies now use the dictionary
form, and a cross-tool test holds every joaat copy in tools/ to it.
2026-11-22 17:21:26 +00:00
f698bf2206 tools: a path outside the console's code page no longer crashes a tool's output
On Windows a redirected stdout uses the console's ANSI code page, and python -I ignores PYTHONUTF8 and
PYTHONIOENCODING, so a caller path with a character outside that code page ended a run with
UnicodeEncodeError as soon as a tool printed it. #1406 fixed make_game.py; every CLI tool in tools/ now starts
its __main__ block the same way (stdout errors="replace").

tests/test_tool_stdout_encoding.py checks every tool's __main__ block and reruns two measured crashes
(analyze_4240_full.py, meshlet_page.py) with a private-use-named input. Found by @abilliontokens.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-22 11:27:00 +00:00
2fda452e09 Stream joined music records and report their source-file offsets 2026-11-21 22:51:22 -07:00
015d4ed28a audio_config.py: validate --min-ms/--max-ms range and reject --join on a file 2026-11-22 01:42:02 +00:00
166eeee2a0 audio_config.py: a missing source or unreadable input is one line
A missing source went through files_in() as a folder and ended in a
FileNotFoundError traceback from os.listdir. A --names pool that is
missing or a folder, and a stream that can't be read, ended the same
way. Each now exits through sys.exit() with one line naming the path,
like the tool's existing "no audio-config records found" message.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-22 01:52:45 +01:00
f1eb8d3ee1 audio_config.py: locate joined records by file offset 2026-11-22 01:01:59 +01:00
7b2bf8cf61 audio_config.py: stream input files when scanning without --join 2026-11-22 00:23:40 +01:00
2a283c9b21 Merge pull request #297 from dcastell1 2026-11-21 17:38:21 -05:00
6516dfea46 fix(tools): report clear errors for empty, short and out-of-range input
BUILD-30: anim_index, rbf0_index and restofworld_index now reject an
empty archive with a named error instead of mmap's traceback.
rpf9_carve rejects an empty or shorter-than-header archive and a
--start at or past the file size before it divides by the span.
audio_config exits with a named error when the input has no records
instead of formatting None as a hex id.

The new synthetic test covers every case; the existing tests for the
five tools still pass.
2026-11-21 23:31:48 +01:00
56f9e66f60 Tools: add a title-to-stream-id helper for untitled config records 2026-11-21 21:44:48 +00:00
008aa3d3b0 Tools: parse the audio-config music record table 2026-11-21 19:13:50 +00:00