运行 apt-get update 并重新启动计算机后,尝试通过 Lutris 通过 Wine 运行游戏时开始出现此错误。
Error while completing task <bound method wine.prelaunch of <lutris.runners.wine.wine object at 0x7f78b5251040>>: <class 'AttributeError'> 'NoneType' object has no attribute 'lower'
File "/usr/lib/python3/dist-packages/lutris/util/jobs.py", line 34, in target
result = self.function(*args, **kwargs)
File "/usr/lib/python3/dist-packages/lutris/runners/wine.py", line 819, in prelaunch
self.setup_dlls(
File "/usr/lib/python3/dist-packages/lutris/runners/wine.py", line 776, in setup_dlls
if dll_manager.version.lower() != "manual":
2022-04-30 12:36:05,162: 'NoneType' object has no attribute 'lower'
把这个放在这里是为了分享知识!
我的解决方案是注释掉下面的函数/usr/lib/python3/dist-packages/lutris/runners/wine.py
,如下所示:
def setup_dlls(self, manager_class, enable, version):
"""Enable or disable DLLs"""
# dll_manager = manager_class(
# self.prefix_path,
# arch=self.wine_arch,
# version=version,
# )
# # manual version only sets the dlls to native
# if dll_manager.version.lower() != "manual":
# if enable:
# dll_manager.enable()
# else:
# dll_manager.disable()
#
# if enable:
# for dll in dll_manager.managed_dlls:
# # We have to make sure that the dll exists before setting it to native
# if dll_manager.dll_exists(dll):
# self.dll_overrides[dll] = "n"
这显然不是一个长期的解决方案,但游戏目前仍能正常运行。 - 我的问题是:有人对长期解决方案/永久解决方案有什么想法吗?