We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents 58df797 + b3a7d6f commit 52dddd9Copy full SHA for 52dddd9
1 file changed
devito/arch/compiler.py
@@ -297,7 +297,13 @@ def load(self, soname):
297
obj
298
The loaded shared object.
299
"""
300
- return npct.load_library(str(self.get_jit_dir().joinpath(soname)), '.')
+ try:
301
+ return npct.load_library(str(self.get_jit_dir().joinpath(soname)), '.')
302
+ except AttributeError as e:
303
+ # Some ctypes paths re-wrap dlopen failures, such as a partially
304
+ # written .so, as AttributeError. Normalize so jit_compile treats
305
+ # the probe as a cache miss and enters codepy's locked compile path.
306
+ raise OSError(str(e)) from e
307
308
def save_header(self, filename, code):
309
0 commit comments