mirror of
https://github.com/ubiquitarianism/leonida.git
synced 2026-11-26 22:00:52 +01:00
[PR #2254] scripts/check_compute_journal_overlay: validate journal dirs/exe, enforce UTF-8, extract main, add tests #2256
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#2256
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/2254
Author: @kirigayakazima
Created: 11/26/2026
Status: 🔄 Open
Base:
main← Head:fix/check-compute-journal-overlay-safety📝 Commits (1)
aa95d15Harden check_compute_journal_overlay checks, encoding, main entry, and tests📊 Changes
2 files changed (+180 additions, -12 deletions)
View changed files
📝
scripts/check_compute_journal_overlay.py(+35 -12)➕
tests/test_check_compute_journal_overlay.py(+145 -0)📄 Description
Claimed in the coordination issue as: CHECK-COMPUTE-JOURNAL-OVERLAY-SAFETY-AND-TESTS (https://github.com/ubiquitarianism/leonida/issues/1608#issuecomment-7189582869)
What and why
d.is_dir()inentries()(scripts/check_compute_journal_overlay.py) before iteratingpipeline_cache.d.new-B/pipeline_cache.dandcold/pipeline_cache.dwith explicit directory, single-entry, and.is_file()checks giving clearRuntimeErrormessages.encoding="utf-8"alongsideerrors="replace"insubprocess.run(...)so redirected stdout/stderr does not depend on the host ANSI code page.main(argv=None) -> intvalidating executable existence/regular-file status and allowing bothd3d12_compute_journal_test.exeand POSIXd3d12_compute_journal_test, catching runtime errors cleanly onstderrwith exit status1/2.tests/test_check_compute_journal_overlay.py.Tested
python -I tests/test_check_compute_journal_overlay.py -v->Ran 3 tests in 0.755s(OK).upstream/maina73a57e1withtests/test_check_compute_journal_overlay.pycopied into detached worktree):Ran 3 tests in 0.027s(FAILED (errors=3)).python -I tests/test_ci_registration.py(Ran 16 tests in 13.847s,OK),python -I tests/test_text_write_line_endings.py(Ran 3 tests in 17.336s,OK),python -I scripts/check_no_game_data.py(exit 0),python -I -m compileall -q(exit 0),git diff --check(exit 0).GPUs tested: n/a (mocked subprocess harness and CLI validation tests)
AI-assisted: yes
Checklist
mainand merges cleanly (a conflicting pull request is labeledneeds rebase).docs/design.md, with how it was confirmed.🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.