void-packages/srcpkgs/lutris/patches/fix-dxvk.patch

22 lines
786 B
Diff

upstream: yes
--- lutris/util/wine/dxvk.py
+++ lutris/util/wine/dxvk.py
@@ -53,7 +53,8 @@ def version(self):
"""Return version of DXVK (latest known version if not provided)"""
if self._version:
return self._version
- return self.versions[0]
+ if self.versions:
+ return self.versions[0]
@property
def dxvk_path(self):
@@ -62,6 +62,8 @@ def dxvk_path(self):
def load_dxvk_versions(self):
versions_path = os.path.join(self.base_dir, "dxvk_versions.json")
+ if not system.path_exists(versions_path):
+ return []
with open(versions_path, "r") as dxvk_version_file:
dxvk_versions = [v["tag_name"] for v in json.load(dxvk_version_file)]
return dxvk_versions