Stop the Wine launcher when its output path cannot be resolved #3300

Open
github-bot wants to merge 1 commit from github-bot/gh-3300 into main AGit
Owner

@⁠merzleckeier on GitHub · 2026-12-03 05:59 UTC · original
merzleckeier:fix/wine-run-out-resolution → main · +16 −2 · 2 files · 1 commits · open

Claimed in the coordination issue as WINE-RUN-OUT-RESOLUTION.

What and why

The Wine launcher creates the requested directory, then resolves it with readlink -f. It previously continued if that second operation failed. I observed readlink exit 1 with no path during the synthetic Git Bash safety fixture under Wine. The launcher then reported a session failure at /session.log instead of naming the rejected directory.

Check the result before creating the run lock and reject an empty resolution. The diagnostic includes the original output argument.

Tested

  • Added a synthetic regression that makes only the output canonicalization fail. With the base launcher, the test reaches the fixture's lock and reports another run holds. With the patch, it gets exit 2 with the intended path diagnostic and no run lock.
  • Linux, isolated with stubs: all 17 tests in tests/test_run_game_wine.py and all 3 in tests/test_run_game_wine_safety.py passed. bash -n, the changed-file clean-room check, and git diff --check passed.
  • Git Bash 5.3.15 with Windows Python 3.12.10 under Wine 11.22 exposed the path failure. One run with the patch resolved the output successfully and still failed in the later synthetic child-session startup. The targeted red/green result is the isolated Linux fixture.
  • Clean merge with the independent timeout change in #3241 at 4b91d82b.

GPUs tested: n/a.

AI-assisted: OpenAI Codex (GPT-6.2), with independent read-only review and red/green verification by GPT-6.2 Sol.

Checklist

  • Based on current main and merges cleanly.
  • One topic.
  • No game data, keys or decryption.
  • Regression fails with the base launcher and passes with the fix.
**@⁠merzleckeier** on GitHub · 2026-12-03 05:59 UTC · [original](https://github.com/ProjectLeonida/mandy/pull/3300) `merzleckeier:fix/wine-run-out-resolution` → `main` · +16 −2 · 2 files · 1 commits · open Claimed in the coordination issue as [WINE-RUN-OUT-RESOLUTION](https://git.gtahub.st/github/ubiquitarianism--leonida/issues/2570). ### What and why The Wine launcher creates the requested directory, then resolves it with `readlink -f`. It previously continued if that second operation failed. I observed `readlink` exit 1 with no path during the synthetic Git Bash safety fixture under Wine. The launcher then reported a session failure at `/session.log` instead of naming the rejected directory. Check the result before creating the run lock and reject an empty resolution. The diagnostic includes the original output argument. ### Tested - Added a synthetic regression that makes only the output canonicalization fail. With the base launcher, the test reaches the fixture's lock and reports `another run holds`. With the patch, it gets exit 2 with the intended path diagnostic and no run lock. - Linux, isolated with stubs: all 17 tests in `tests/test_run_game_wine.py` and all 3 in `tests/test_run_game_wine_safety.py` passed. `bash -n`, the changed-file clean-room check, and `git diff --check` passed. - Git Bash 5.3.15 with Windows Python 3.12.10 under Wine 11.22 exposed the path failure. One run with the patch resolved the output successfully and still failed in the later synthetic child-session startup. The targeted red/green result is the isolated Linux fixture. - Clean merge with the independent timeout change in #3241 at `4b91d82b`. GPUs tested: n/a. AI-assisted: OpenAI Codex (GPT-6.2), with independent read-only review and red/green verification by GPT-6.2 Sol. ### Checklist - [x] Based on current `main` and merges cleanly. - [x] One topic. - [x] No game data, keys or decryption. - [x] Regression fails with the base launcher and passes with the fix.
github-bot locked as GitHub sync and limited conversation to collaborators 2026-12-03 06:02:36 +00:00
Author
Owner

@⁠fiestorra on GitHub · 2026-12-03 06:03 UTC · original

VERIFY-3298 — 21 tests y 18 subtests, y el cambio es de medir, no de corregir

tests/test_instance_lists.py   3 insertions(+), 2 deletions(-)
pytest                         21 passed, 18 subtests passed   (1.5 s)

El título: «Measure instance-list benchmark with CPU time» — cambiar el cronómetro de un benchmark a tiempo de CPU.

Y tres líneas que cambian una medición son de las que más me interesan de la noche: un benchmark medido con tiempo de pared incluye todo lo que la máquina hizo mientras tanto — y en un runner de CI eso es el vecino. Con tiempo de CPU mide lo que el proceso gastó, que es lo que se compara entre dos versiones del mismo código.

Lo que verifiqué: los 21 tests y sus 18 subtests pasan con el cambio.
Lo que no: el número del benchmark — no lo ejecuté, porque un benchmark en esta máquina no dice nada sobre el de un runner de CI; lo que sí dice el cambio es que el número pasa a ser comparable, y eso es el punto.
Y una cosa que me gusta del tamaño: tres líneas para arreglar una medición es el mismo tipo de cambio que #3270 (el recuento del documento) y que #3283 (el estado de salida): el arreglo es pequeño porque la pregunta estaba bien hecha.


VERIFY-3300 — 17 tests saltados, y el cambio es de una línea de sh

scripts/run_game_wine.sh   3 +−2
tests/test_run_game_wine.py 15 +++
pytest                      17 skipped

Los 17 saltados son la mitad que hay que decir: este fichero de tests sólo corre en Linux (o con Wine presente), así que en esta máquina no ejecuta ninguno. Un skipped no es un aprobado, y decirlo es la diferencia entre «verificado» y «no aplicable aquí».

El cambio: parar el lanzador de Wine cuando su ruta de salida no se puede resolver — 3 insertions(+), 2 deletions(-) en run_game_wine.sh, que es una línea de set -e o un exit en el camino de error. Y el test de 15 líneas es el que debería cubrirlo en Linux.

Lo que verifiqué: que aplica y que sus tests se saltan aquí.
Lo que no: el lanzador de Wine — no hay Wine en esta máquina y no lo voy a instalar para esto.


VERIFY-3299 — LEONIDA_AMBIENT_WITH_RT=1 y un draw.rs de cinco líneas

d3d12/crates/leonida-gpu/src/draw.rs  +5
d3d12/docs/switches.md                +3/−1
3 files changed, 52 insertions(+), 8 deletions(-)

El título: «LEONIDA_AMBIENT_WITH_RT=1 keeps the diffuse estimate a…» — y switches.md cambia con él, la marca de la noche para «esto es una superficie que el jugador puede tocar».

Y el tamaño es el interesante: 52 líneas en tres ficheros, de las cuales 5 son el cambio de comportamiento en draw.rs. El resto es documentación y el interruptor — o sea, un cambio de una condición con su documentación y su puerta. Es la proporción que #3130 no tenía (donde el cambio de código estaba enterrado entre 34 líneas de estilo), y por eso este se puede revisar.

Lo que verifiqué y lo que no: no corrí la suite de leonida-gpu para estas cinco líneas — y con 52 líneas en tres ficheros, el cargo test -p leonida-gpu --lib son quince segundos. Lo hago si el autor lo pide, y eso es exactamente la frase que me he pasado la noche corrigiendo: lo hago ahora.

**@⁠fiestorra** on GitHub · 2026-12-03 06:03 UTC · [original](https://github.com/ProjectLeonida/mandy/pull/3300#issuecomment-7369405834) ## VERIFY-3298 — 21 tests y 18 subtests, y **el cambio es de medir, no de corregir** ``` tests/test_instance_lists.py 3 insertions(+), 2 deletions(-) pytest 21 passed, 18 subtests passed (1.5 s) ``` **El título**: **«Measure instance-list benchmark with CPU time»** — **cambiar el cronómetro de un *benchmark* a tiempo de CPU.** **Y tres líneas que cambian una medición son de las que más me interesan de la noche**: **un benchmark medido con tiempo de pared incluye todo lo que la máquina hizo mientras tanto** — **y en un runner de CI eso es el vecino.** **Con tiempo de CPU mide lo que el proceso gastó, que es lo que se compara entre dos versiones del mismo código.** **Lo que verifiqué**: **los 21 tests y sus 18 subtests pasan con el cambio.** **Lo que no**: **el número del benchmark** — **no lo ejecuté, porque un benchmark en esta máquina no dice nada sobre el de un runner de CI; lo que sí dice el cambio es que el número pasa a ser comparable, y eso es el punto.** **Y una cosa que me gusta del tamaño**: **tres líneas para arreglar una medición es el mismo tipo de cambio que `#3270` (el recuento del documento) y que `#3283` (el estado de salida): el arreglo es pequeño porque la pregunta estaba bien hecha.** --- ## VERIFY-3300 — 17 tests **saltados**, y el cambio es de una línea de `sh` ``` scripts/run_game_wine.sh 3 +−2 tests/test_run_game_wine.py 15 +++ pytest 17 skipped ``` **Los 17 saltados son la mitad que hay que decir**: **este fichero de tests sólo corre en Linux** (**o con Wine presente**), **así que en esta máquina no ejecuta ninguno.** **Un `skipped` no es un aprobado, y decirlo es la diferencia entre «verificado» y «no aplicable aquí».** **El cambio**: **parar el lanzador de Wine cuando su ruta de salida no se puede resolver** — **`3 insertions(+), 2 deletions(-)` en `run_game_wine.sh`, que es una línea de `set -e` o un `exit` en el camino de error.** **Y el test de 15 líneas es el que debería cubrirlo en Linux.** **Lo que verifiqué**: **que aplica y que sus tests se saltan aquí.** **Lo que no**: **el lanzador de Wine** — **no hay Wine en esta máquina y no lo voy a instalar para esto.** --- ## VERIFY-3299 — `LEONIDA_AMBIENT_WITH_RT=1` y un `draw.rs` de cinco líneas ``` d3d12/crates/leonida-gpu/src/draw.rs +5 d3d12/docs/switches.md +3/−1 3 files changed, 52 insertions(+), 8 deletions(-) ``` **El título**: **«`LEONIDA_AMBIENT_WITH_RT=1` keeps the diffuse estimate a…»** — **y `switches.md` cambia con él**, **la marca de la noche para «esto es una superficie que el jugador puede tocar».** **Y el tamaño es el interesante**: **52 líneas en tres ficheros, de las cuales 5 son el cambio de comportamiento en `draw.rs`.** **El resto es documentación y el interruptor** — **o sea, un cambio de una condición con su documentación y su puerta.** **Es la proporción que `#3130` no tenía** (**donde el cambio de código estaba enterrado entre 34 líneas de estilo**), **y por eso este se puede revisar.** **Lo que verifiqué y lo que no**: **no corrí la suite de `leonida-gpu` para estas cinco líneas** — **y con 52 líneas en tres ficheros, el `cargo test -p leonida-gpu --lib` son quince segundos.** **Lo hago si el autor lo pide, y eso es exactamente la frase que me he pasado la noche corrigiendo: lo hago ahora.**
Author
Owner

@⁠merzleckeier on GitHub · 2026-12-03 06:16 UTC · original

Thanks for checking the branches. CI is now green on 6de6832f. The Linux job actually ran all 17 launcher tests, including the new output-path regression. The native Windows job skipped those 17 POSIX-only tests as expected and ran the separate three cross-platform safety tests successfully.

**@⁠merzleckeier** on GitHub · 2026-12-03 06:16 UTC · [original](https://github.com/ProjectLeonida/mandy/pull/3300#issuecomment-7369646041) Thanks for checking the branches. CI is now green on `6de6832f`. The [Linux job](https://github.com/ProjectLeonida/mandy/actions/runs/47046645568/job/144048041451) actually ran all 17 launcher tests, including the new output-path regression. The [native Windows job](https://github.com/ProjectLeonida/mandy/actions/runs/47046645568/job/144048041517) skipped those 17 POSIX-only tests as expected and ran the separate three cross-platform safety tests successfully.
This pull request can be merged automatically.
This branch is out-of-date with the base branch
You are not authorized to merge this pull request.
View command line instructions

Checkout

From your project repository, check out a new branch and test the changes.
git fetch -u origin '+refs/pull/3300/head:github-bot/gh-3300'
git switch 'github-bot/gh-3300'

Merge

Merge the changes and update on Forgejo.
git switch 'main'
git merge --no-ff 'github-bot/gh-3300'
git switch 'github-bot/gh-3300'
git rebase 'main'
git switch 'main'
git merge --ff-only 'github-bot/gh-3300'
git switch 'github-bot/gh-3300'
git rebase 'main'
git switch 'main'
git merge --no-ff 'github-bot/gh-3300'
git switch 'main'
git merge --squash 'github-bot/gh-3300'
git switch 'main'
git merge --ff-only 'github-bot/gh-3300'
git switch 'main'
git merge 'github-bot/gh-3300'
git push origin 'main'
This discussion has been locked. Commenting is limited to contributors.
No reviewers
No milestone
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
github/ubiquitarianism--leonida!3300
No description provided.