Skip to content

run_wine_session: initialize and stop the prefix with $WINE (OLD-9952) - #1241

Merged
MoonEyes merged 1 commit into
ProjectLeonida:mainfrom
IlyassRS3:carry/old-9952-run-wine-session
Nov 28, 2026
Merged

MoonEyes merged 1 commit into
ProjectLeonida:mainfrom
IlyassRS3:carry/old-9952-run-wine-session

Conversation

@IlyassRS3

Copy link
Copy Markdown
Contributor

What changed

Carries forward old-pr/9952 (draft #221, original commit by @SkippySteve) rebased cleanly onto current main (2e026b03e), preserving the original author commit.

  • scripts/run_wine_session.sh: resolve $WINE (default wine) via command -v (reporting missing Wine with exit status 127), run "$wine_path" wineboot --init instead of bare wineboot, and shut down the prefix with $WINESERVER, else the sibling wineserver next to $wine_path, else wineserver on PATH.
  • docs/testing.md: document $WINE / sibling wineserver / $WINESERVER prefix handling for Proton and UMU-Proton builds without a system Wine.
  • tests/test_run_wine_session.py: add 4 unit tests covering Proton $WINE + sibling wineserver, default wine on PATH, $WINESERVER override + PATH fallback, and missing $WINE exit 127 reporting.

Item ID

Verification

Tested on macOS 27.2.1 (Apple M5 arm64), Python 3.14, bash + /usr/bin/timeout (no game files, no GPU, standard library only):

  • TMPDIR=/var/tmp python3 -I tests/test_run_wine_session.py -v -> 4/4 OK
  • Revert-source mutation check (reverting scripts/run_wine_session.sh to upstream/main while keeping tests/test_run_wine_session.py) -> FAILED (failures=4) (all 4 tests fail); restoring the fix returns to 4/4 OK.
  • All 12 tests/test_docs_*.py suites -> all OK
  • python3 -I tests/test_ci_registration.py -> 15/15 OK (new test file selected by CI stdlib loop)
  • python3 -I tests/test_text_write_line_endings.py -> 3/3 OK
  • python3 -m compileall -q tests/test_run_wine_session.py -> OK
  • python3 -I scripts/check_no_game_data.py docs/testing.md scripts/run_wine_session.sh tests/test_run_wine_session.py -> OK

Checklist

  • No game files, binaries, shaders, textures, audio, or logs quoting them
  • No keys, decryption, or online services
  • Claimed in the coordination issue (Coordinating who works on what #14) before opening this PR
  • AI-assisted: yes (carried forward, audited, rebased, and regression-verified with AI assistance; original commit by @SkippySteve preserved)

The session script ran wineboot and wineserver from PATH while
run_wine_tests.py runs the tests with $WINE. With WINE set to Proton's or
UMU-Proton's files/bin/wine, the prefix was initialized by another Wine, or
the script stopped at 'wineboot: command not found' on a host without a
system Wine, and the exit trap stopped the wrong wineserver.

Run "$WINE" wineboot --init and stop $WINESERVER, else the wineserver next
to $WINE, else wineserver on PATH; report a missing $WINE with status 127.
Copilot AI balanced review requested due to automatic review settings November 24, 2026 20:43

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot was unable to review this pull request because the user who requested the review has insufficient remaining quota. Try requesting a review at a lower effort level.

@MoonEyes

Copy link
Copy Markdown
Collaborator

Red/green: tests/test_run_wine_session.py fails 4 assertions on main (the prefix is started and stopped with the PATH wine/wineserver, not $WINE) and passes with the PR (Linux cloud run on main 7daa4a4; skipped on Windows).
Targeted batch (PR tests, tests importing the changed modules, docs tests, translator when touched) merged on main 7daa4a4 in GitHub Actions: no new failure.
AI-assisted (Claude Code, Claude Opus 5.5)

@MoonEyes
MoonEyes merged commit 8e1875a into ProjectLeonida:main Nov 28, 2026
1 check failed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants