diff --git a/ioos_qc/qartod.py b/ioos_qc/qartod.py index c256dfc..80336cf 100644 --- a/ioos_qc/qartod.py +++ b/ioos_qc/qartod.py @@ -10,6 +10,11 @@ import numpy as np import pandas as pd +try: + from numba.core.errors import NumbaTypeError +except ImportError: + NumbaTypeError = TypeError + from ioos_qc.utils import ( isnan, isfixedlength, @@ -739,7 +744,7 @@ def window_func(w): # When pandas>=1.0 and numba are installed, this is about twice as fast try: return w.apply(np.ptp, raw=True, engine='numba') - except (ImportError, TypeError): + except (ImportError, TypeError, NumbaTypeError): return w.apply(np.ptp, raw=True) check_func = np.ptp else: diff --git a/requirements-dev.txt b/requirements-dev.txt index a880f80..c644540 100644 --- a/requirements-dev.txt +++ b/requirements-dev.txt @@ -4,6 +4,6 @@ erddapy flake8 isort nco -numba<0.57 +numba pytest pytest-flake8>=1.0.4 # https://github.com/tholo/pytest-flake8/pull/59