Skip to content

Commit aeea9b4

Browse files
committed
fixed bug
1 parent 6854b0e commit aeea9b4

File tree

1 file changed

+6
-5
lines changed

1 file changed

+6
-5
lines changed

stumpy/cache.py

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -129,14 +129,15 @@ def _recompile(func=None, fastmath=None):
129129
None
130130
"""
131131
warnings.warn(CACHE_WARNING)
132-
njit_funcs = get_njit_funcs()
132+
133+
njit_funcs = []
134+
for module_name, func_name in get_njit_funcs():
135+
module = importlib.import_module(f".{module_name}", package="stumpy")
136+
njit_funcs.append(getattr(module, func_name))
133137

134138
recompile_funcs = []
135139
if func is None:
136-
for module_name, func_name in njit_funcs:
137-
module = importlib.import_module(f".{module_name}", package="stumpy")
138-
func = getattr(module, func_name)
139-
recompile_funcs.append(func)
140+
recompile_funcs = njit_funcs
140141
elif func in njit_funcs:
141142
recompile_funcs.append(func)
142143
else:

0 commit comments

Comments
 (0)