mirror of
https://github.com/ubiquitarianism/leonida.git
synced 2026-11-26 22:50:53 +01:00
[PR #1964] Keep Wine runner resources scoped to one prefix owner #1971
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#1971
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/1964
Author: @lgr123
Created: 11/25/2026
Status: 🔄 Open
Base:
main← Head:lgr123/wine-prefix-ownership📝 Commits (1)
7bb0237Keep Wine runner resources scoped to one prefix owner📊 Changes
2 files changed (+87 additions, -1 deletions)
View changed files
📝
scripts/run_wine_tests.py(+33 -1)📝
tests/test_run_wine_tests.py(+54 -0)📄 Description
Claimed in the coordination issue as WINE-PREFIX-RUNNER-OWNERSHIP.
What and why
Two direct invocations of the Wine runner can share a temporary mapping in the same prefix. On main, two independent processes both read a synthetic fixture through D:. The first passed and removed its link on exit. The second then failed because the link was gone. Separately, an owner stopping its kept wineserver can interrupt a borrower.
On POSIX, hold an exclusive nonblocking lock on the Wine prefix directory from before mapping or server setup through teardown. A simultaneous invocation gets a usage error. A symlink to the same prefix shares the lock. Distinct prefixes can still run in parallel, --jobs within a run is unchanged, and the lock leaves no file behind. The runner creates an empty prefix directory if it needs one for the lock. This scopes ownership among direct runner invocations. The session wrapper continues to call for its own dedicated test prefix.
Tested
9e7720c9and passed after the change. The new integration regression failed on main, then confirmed that the symlink alias was rejected, a separate prefix could run, and the original prefix could be reused after teardown.GPUs tested: n/a.
AI-assisted: yes.
Checklist
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.