bink_play: honor --no-cache without persistent storage (BINK-NO-CACHE) #566
No reviewers
Labels
No labels
accessibility
bug
documentation
duplicate
enhancement
good first issue
help wanted
invalid
missing claim
needs rebase
question
wontfix
No milestone
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
github/ubiquitarianism--leonida!566
Loading…
Reference in a new issue
No description provided.
Delete branch "gh-pr/566/head"
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?
@JiyouProt on GitHub · 2026-11-24 08:27 UTC · original
JiyouProt:codex/bink-no-cache→main· +80 −9 · 2 files · 1 commits · merged 2026-11-25 19:46 UTCClaimed in the coordination issue as: BINK-NO-CACHE
What and why
--no-cachestill consulted the persistent cache path, created its parent directory and placed the temporary names report there. Thus listing with caching disabled failed if that cache directory was unavailable (reproduced with an existing file at the directory path), and a successful uncached lookup still created persistent directories.Only resolve, read and create the persistent cache when caching is enabled. Uncached lookups use the system temporary directory and retain the existing report cleanup on success and failure. Existing cache contents remain untouched. The cached path, invalidation keys and concurrent lookup behavior are unchanged.
Four synthetic regressions cover CLI listing with an unusable cache directory, no directory creation, preservation of an existing cache and cleanup after report-generation failure. All four fail on the original source.
Tested
Windows 11 build 26300.9974, Python 3.14.3, based on main
1c93c86970.python -I tests/test_bink_play.py: 14 passed, including the existing cache/invalidation/concurrency tests.python -I tests/test_text_write_line_endings.py: 3 passed.make_game.py --helpandbink_play.py --help, changed-file no-game-data scan andgit diff --check: passed.test_bink_names.py: 35/36 passed. The Windows path-representation assertion intest_unreadable_mount_directory_preserves_the_reportfails identically in an untouched checkout of the same main. This is already covered by #312 and is independent of this change.GPUs tested: n/a — only synthetic CSV/XML fixtures, no movie data, codec or GPU needed.
AI-assisted: yes, Codex.
Checklist
@kirigayakazima on GitHub · 2026-11-24 12:28 UTC · original
Reviewed on Windows 11 x64 (
Python 3.14.7, CPU only, synthetic fixtures only — no game files) against head commit58d6fe27c11ebea71ac3c443353662445ba5eff9.Verdict: Looks good —
--no-cachenow avoids reading, creating, or writing anything in the persistent cache directory and stages temporarybink_namesoutput in the system temporary directory with cleanup on both success and failure.Checks run locally
main(21625bca):git merge-tree --write-tree upstream/main HEADexited0;git diff --check upstream/main...HEADclean.09867f49):git merge-tree --write-tree HEAD <PR-568-head>exited0(both changes intools/bink_play.pycompose cleanly with no conflicts).python -I tests/test_bink_play.py -v: 14 tests, OK.python -I tests/test_ci_registration.py: 15 tests, OK.python -I tests/test_text_write_line_endings.py: 3 tests, OK.python -I scripts/check_no_game_data.py tools/bink_play.py tests/test_bink_play.pyandpython -m compileall -q tools tests: clean (exit0).Additional Windows edge-case probes
LOCALAPPDATApointing to a regular file with--no-cache --list: exited0, printed synthetic stream entry, left the blocker file untouched, staged.tmp.csvunder the system temp folder, and left no temporary files behind.load_names(..., use_cache=False): skipped cache lookup cleanly, returned fresh parsed entries, and left existing cache bytes intact.bink_names.mainreturn (rc=2) underuse_cache=False: raisedSystemExit, removed the temporary report from system temp, and did not create the cache directory.AI-assisted: yes
@JiyouProt on GitHub · 2026-11-24 20:18 UTC · original
Rechecked head
58d6fe27against current main58be9cdf8on Windows / Python 3.14.3. It merges cleanly. On the combined tree: test_bink_play 14/14, test_bink_play_cache_write 3/3, CI registration 15/15 and LF writers 3/3 pass; changed-file no-game-data and whitespace checks are clean. CI registration was run outside the local sandbox because it needs Git Bash.I also merged #840 (
d6cee3e10, the fd-cleanup follow-up to #568) into that local integration tree: no conflicts, test_bink_play 16/16 and test_bink_play_cache_write 3/3 pass. Thus the no-cache behavior here composes with that cache-error cleanup. No code or branch update is needed for #566. Synthetic inputs only, no GPU or game files. AI-assisted with Codex.@aslan2142 on GitHub · 2026-11-25 19:46 UTC · original
Merged, thanks! The new test fails on
mainand passes with this.main8c40e3b7a+58d6fe27c: the semantic suite passes (491 files, 6,312 tests, 0 files failed);test_bink_playpass; the 15 docs and writer tests pass;check_no_game_data.pyis clean on the 2 changed files.AI-assisted (Claude Code, Claude Opus 5.5).