Launchers: discover versioned Python (SHELL-LAUNCHERS-PYTHON315) #1942

Merged
d6ge-dev merged 1 commit from upstream-pr/1942 into main 2026-11-28 13:24:46 +00:00
d6ge-dev commented 2026-11-25 16:20:43 +00:00 (Migrated from github.com)

Imported from ubiquitarianism/leonida. Originally posted by d6ge-dev on 2026-11-25T16:20:43Z.


Claimed in the coordination issue as: SHELL-LAUNCHERS-PYTHON315 in #1608

What and why

Build.sh and Mods.sh rejected a supported Python installation when python3.15 was the only usable interpreter on PATH. Both launchers now use a shared POSIX helper to discover versioned Python commands and select the highest usable minor version. The helper follows normal PATH precedence for duplicate names and keeps the python3 and python fallbacks.

Tested

  • Reproduced both launcher failures on main with a synthetic PATH and an older python3.
  • python3 -I tests/test_shell_launchers.py passed all 7 tests. The new case covers later minor versions, duplicate names, spaces on PATH, and argument forwarding for both launchers.
  • Shell syntax, git diff --check, and the no-game-data check passed for the changed files.

GPUs tested: n/a (CPU-only launcher tests)

AI-assisted: yes

Checklist

  • Based on current main when prepared.
  • One topic.
  • No game data, keys, or decryption.
<!-- greyfinch-sync:ubiquitarianism/leonida:issue:5494976738 --> Imported from [ubiquitarianism/leonida](https://github.com/ProjectLeonida/mandy/pull/1942). Originally posted by [d6ge-dev](https://github.com/d6ge-dev) on 2026-11-25T16:20:43Z. --- Claimed in the coordination issue as: `SHELL-LAUNCHERS-PYTHON315` in #1608 ### What and why `Build.sh` and `Mods.sh` rejected a supported Python installation when `python3.15` was the only usable interpreter on `PATH`. Both launchers now use a shared POSIX helper to discover versioned Python commands and select the highest usable minor version. The helper follows normal `PATH` precedence for duplicate names and keeps the `python3` and `python` fallbacks. ### Tested - Reproduced both launcher failures on `main` with a synthetic `PATH` and an older `python3`. - `python3 -I tests/test_shell_launchers.py` passed all 7 tests. The new case covers later minor versions, duplicate names, spaces on `PATH`, and argument forwarding for both launchers. - Shell syntax, `git diff --check`, and the no-game-data check passed for the changed files. GPUs tested: n/a (CPU-only launcher tests) AI-assisted: yes ### Checklist - [x] Based on current `main` when prepared. - [x] One topic. - [x] No game data, keys, or decryption.
MoonEyes commented 2026-11-28 13:24:53 +00:00 (Migrated from github.com)

Imported from ubiquitarianism/leonida. Originally posted by MoonEyes on 2026-11-28T13:24:53Z.


Merged after local re-verification: this PR merged onto main a8e427b44 without conflict, and its test file(s) (tests/test_shell_launchers.py) pass there. Earlier today the same tests failed on main without the PR (red/green) and a bundle with other open PRs showed no new failures. check_no_game_data.py is clean. Windows 11, Python 3.14; no GPU needed for these tests.

AI-assisted (Claude Code, Claude Opus 5.5), merged for MoonEyes.

<!-- greyfinch-sync:ubiquitarianism/leonida:comment:7239918297 --> Imported from [ubiquitarianism/leonida](https://github.com/ProjectLeonida/mandy/pull/1942#issuecomment-7239918297). Originally posted by [MoonEyes](https://github.com/MoonEyes) on 2026-11-28T13:24:53Z. --- Merged after local re-verification: this PR merged onto `main` a8e427b44 without conflict, and its test file(s) (`tests/test_shell_launchers.py`) pass there. Earlier today the same tests failed on `main` without the PR (red/green) and a bundle with other open PRs showed no new failures. `check_no_game_data.py` is clean. Windows 11, Python 3.14; no GPU needed for these tests. _AI-assisted (Claude Code, Claude Opus 5.5), merged for MoonEyes._
Sign in to join this conversation.
No reviewers
No labels
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.

Reference
ProjectLeonida/mandy!1942
No description provided.