Fix py 3.7 compatibility
Revert "Use lru_cache directly for py<3.8"
This reverts commit
except ImportError:
# For py<3.9
# https://docs.python.org/3.9/library/functools.html
- from functools import lru_cache as memoize
+ from functools import lru_cache
+
+
+ def memoize(user_function):
+ return lru_cache(maxsize=None)(user_function)
