[PR #75] [MERGED] tests: compare the fuzzer and first-look paths after resolve() #127

Closed
opened 2026-11-26 20:16:53 +01:00 by 4ld0 · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/ubiquitarianism/leonida/pull/75
Author: @wavehs
Created: 11/24/2026
Status: ✅ Merged
Merged: 11/24/2026
Merged by: @ubiquitarianism

Base: main ← Head: tests-win-canonical-paths


📝 Commits (1)

  • a54fec1 tests: compare the fuzzer and first-look paths after resolve()

📊 Changes

2 files changed (+8 additions, -4 deletions)

View changed files

📝 tests/test_first_look_paths.py (+3 -1)
📝 tests/test_fuzzer_work_isolation.py (+5 -3)

📄 Description

Claimed in the coordination issue as: none — the original project's coordination issue was lost with its repository, and this repository's issue index (#18) has no entry for these. No open pull request touches these two files.

Depends on: none.

What and why

Both tools canonicalise the directory they were given before they use it, and the Windows check job fails on the resulting difference — five assertions across two files:

  • tools/lds_fuzz.py:1216 and tools/valu_fuzz.py do parent = Path(a.work).resolve() and print work dir {work} under it. tempfile hands out the 8.3 name on Windows, so the printed folder is C:\Users\runneradmin\... while the test holds C:\Users\RUNNER~1\...:
FAIL: test_failed_translation_reports_retained_output_and_creates_parent ... (fuzzer='lds_fuzz')
AssertionError: 'C:\\Users\\RUNNER~1\\...\\lds_fuzz_b9rtlw83' not found in
              'work dir C:\\Users\\runneradmin\\...\\lds_fuzz_b9rtlw83\nsynthetic failure\n'

(the same assertion for valu_fuzz, and two more in test_existing_files_and_other_runs_survive comparing the same run folders against the captured output)

  • tests/test_first_look_paths.py compares the loader report with str(image) / str(game); PowerShell's Resolve-Path gives the script the long path (runneradmin), not the 8.3 one (RUNNER~1).

Both now compare Path.resolve(), which is what the tools themselves use. On POSIX and on a checkout outside the temporary directory this changes nothing; on macOS the short /var/folders/... path matches only as a suffix of the resolved /private/var/folders/..., which is why this stayed green here.

Tested

macOS 15 arm64 (Apple M3 Pro), CPython 3.15.2, CPU only, no game files:

tree test_fuzzer_work_isolation.py test_first_look_paths.py
main@9ec34cdff OK (passes by the /private suffix accident) OK (skipped=1) — Windows-only
this commit OK OK (skipped=1)

The Windows failure itself is the check job log quoted above (9ec34cdff, run 45306800350, job 138157329747); a short RUNNER~1... string is not found in the runneradmin... message. I have no Windows host to re-run it.

compileall clean, check_no_game_data.py clean. Not run: Windows, any GPU test.

AI-assisted: yes.

Checklist

  • No game data, keys or decryption (CONTRIBUTING.md), including in logs or reports quoted here.
  • A new translator rule is in the contract table of docs/design.md, with how it was confirmed. (Not applicable: test-only.)

🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/ubiquitarianism/leonida/pull/75 **Author:** [@wavehs](https://github.com/wavehs) **Created:** 11/24/2026 **Status:** ✅ Merged **Merged:** 11/24/2026 **Merged by:** [@ubiquitarianism](https://github.com/ubiquitarianism) **Base:** `main` ← **Head:** `tests-win-canonical-paths` --- ### 📝 Commits (1) - [`a54fec1`](https://github.com/ubiquitarianism/leonida/commit/a54fec10025e87a68043c5b4e7d0c57d99c2da68) tests: compare the fuzzer and first-look paths after resolve() ### 📊 Changes **2 files changed** (+8 additions, -4 deletions) <details> <summary>View changed files</summary> 📝 `tests/test_first_look_paths.py` (+3 -1) 📝 `tests/test_fuzzer_work_isolation.py` (+5 -3) </details> ### 📄 Description Claimed in the coordination issue as: none — the original project's coordination issue was lost with its repository, and this repository's issue index (#18) has no entry for these. No open pull request touches these two files. Depends on: none. ### What and why Both tools canonicalise the directory they were given before they use it, and the Windows `check` job fails on the resulting difference — five assertions across two files: - `tools/lds_fuzz.py:1216` and `tools/valu_fuzz.py` do `parent = Path(a.work).resolve()` and print `work dir {work}` under it. `tempfile` hands out the 8.3 name on Windows, so the printed folder is `C:\Users\runneradmin\...` while the test holds `C:\Users\RUNNER~1\...`: ``` FAIL: test_failed_translation_reports_retained_output_and_creates_parent ... (fuzzer='lds_fuzz') AssertionError: 'C:\\Users\\RUNNER~1\\...\\lds_fuzz_b9rtlw83' not found in 'work dir C:\\Users\\runneradmin\\...\\lds_fuzz_b9rtlw83\nsynthetic failure\n' ``` (the same assertion for `valu_fuzz`, and two more in `test_existing_files_and_other_runs_survive` comparing the same run folders against the captured output) - `tests/test_first_look_paths.py` compares the loader report with `str(image)` / `str(game)`; PowerShell's `Resolve-Path` gives the script the long path (`runneradmin`), not the 8.3 one (`RUNNER~1`). Both now compare `Path.resolve()`, which is what the tools themselves use. On POSIX and on a checkout outside the temporary directory this changes nothing; on macOS the short `/var/folders/...` path matches only as a suffix of the resolved `/private/var/folders/...`, which is why this stayed green here. ### Tested macOS 15 arm64 (Apple M3 Pro), CPython 3.15.2, CPU only, no game files: | tree | `test_fuzzer_work_isolation.py` | `test_first_look_paths.py` | |---|---|---| | `main@9ec34cdff` | `OK` (passes by the `/private` suffix accident) | `OK (skipped=1)` — Windows-only | | this commit | `OK` | `OK (skipped=1)` | The Windows failure itself is the `check` job log quoted above (`9ec34cdff`, run 45306800350, job 138157329747); a short `RUNNER~1...` string is not found in the `runneradmin...` message. I have no Windows host to re-run it. `compileall` clean, `check_no_game_data.py` clean. Not run: Windows, any GPU test. AI-assisted: yes. ### Checklist - [x] No game data, keys or decryption (CONTRIBUTING.md), including in logs or reports quoted here. - [ ] A new translator rule is in the contract table of `docs/design.md`, with how it was confirmed. (Not applicable: test-only.) --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
4ld0 2026-11-26 20:16:53 +01:00
Sign in to join this conversation.
No labels
bug
pull-request
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
starred/leonida#127
No description provided.