From 6b1d83d2e69f3c049f4cabcd9f9ea0ecff8eddf0 Mon Sep 17 00:00:00 2001 From: Seunghoon Lee Date: Mon, 24 Mar 2025 21:20:51 +0900 Subject: [PATCH] zluda catch attributeerror --- modules/zluda_installer.py | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/modules/zluda_installer.py b/modules/zluda_installer.py index ae801b4b8..4b915c724 100644 --- a/modules/zluda_installer.py +++ b/modules/zluda_installer.py @@ -47,8 +47,11 @@ class Core(ZLUDALibrary): internal.zluda_get_hip_object.restype = ZLUDAResult internal.zluda_get_hip_object.argtypes = [ctypes.c_void_p, ctypes.c_int] - internal.zluda_get_nightly_flag.restype = ctypes.c_int - internal.zluda_get_nightly_flag.argtypes = [] + try: + internal.zluda_get_nightly_flag.restype = ctypes.c_int + internal.zluda_get_nightly_flag.argtypes = [] + except AttributeError: + internal.zluda_get_nightly_flag = lambda: 0 super().__init__(internal)