Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: auto remove compat tool in home #409

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 12 additions & 0 deletions umu/umu_run.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
from ctypes import CDLL, c_int, c_ulong
from errno import ENETUNREACH
from itertools import chain
from shutil import rmtree
from zipfile import Path as ZipPath

try:
Expand Down Expand Up @@ -863,6 +864,17 @@ def umu_run(args: Namespace | tuple[str, list[str]]) -> int:
raise ValueError(err)
os.environ["RUNTIMEPATH"] = version[1]

# Related to https://github.com/Open-Wine-Components/umu-launcher/issues/394
compat_candidates: set[Path] = {
STEAM_COMPAT / "umu-launcher",
Path.home().joinpath(
".local", "share", "Steam", "compatibilitytools.d", "umu-launcher"
),
}
for compat in compat_candidates:
if compat.is_dir():
rmtree(compat)

# Opt to use the system's native CA bundle rather than certifi's
with suppress(ModuleNotFoundError):
import truststore
Expand Down