diff options
author | Keewis <keewis@posteo.de> | 2019-12-12 13:33:41 +0100 |
---|---|---|
committer | Keewis <keewis@posteo.de> | 2019-12-12 13:33:41 +0100 |
commit | 9d7766514f64fe33e36260a629d944ee4c7cbd41 (patch) | |
tree | 26c56f08fbcde1c2dcc585892fe942eb7790fcdb /pint | |
parent | 43fbae24028edcffaf855916d7c68889b93786e0 (diff) | |
download | pint-9d7766514f64fe33e36260a629d944ee4c7cbd41.tar.gz |
use LegacyVersion instead of StrictVersion which breaks for numpy dev
Diffstat (limited to 'pint')
-rw-r--r-- | pint/quantity.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/pint/quantity.py b/pint/quantity.py index 6d57e42..f05c7cf 100644 --- a/pint/quantity.py +++ b/pint/quantity.py @@ -19,7 +19,7 @@ import operator import re import warnings -from distutils.version import StrictVersion +from pkg_resources.extern.packaging.version import LegacyVersion from .formatting import (remove_custom_flags, siunitx_format_unit, ndarray_to_latex, ndarray_to_latex_parts) @@ -988,7 +988,7 @@ class Quantity(PrettyIPython, SharedRegistryObject): def __matmul__(self, other): # Use NumPy ufunc (existing since 1.16) for matrix multiplication - if StrictVersion(NUMPY_VER) >= StrictVersion('1.16'): + if LegacyVersion(NUMPY_VER) >= LegacyVersion('1.16'): return np.matmul(self, other) else: return NotImplemented |