diff options
author | Charles Harris <charlesr.harris@gmail.com> | 2022-02-04 16:21:58 -0700 |
---|---|---|
committer | Charles Harris <charlesr.harris@gmail.com> | 2022-02-05 10:05:54 -0700 |
commit | df8d1fd3c2077ca785b0948912162e03727ace6c (patch) | |
tree | 01dc1266363997d7fd8e181a2cfefaddaef9751c /numpy/core/setup.py | |
parent | f32f47d58e51111a9c995b2f53dab0d0bdb1c927 (diff) | |
download | numpy-df8d1fd3c2077ca785b0948912162e03727ace6c.tar.gz |
MAINT: Replace LooseVersion by _pep440.
LooseVersion is provided by Python distutils, which is going away in
3.12. This PR vendors _pep440 from scipy and uses it as a replacement.
Numpy distutils is not touched, replacing LooseVersion in that package
was considered too risky, and numpy distutils will need to go away when
Python distutils does.
Diffstat (limited to 'numpy/core/setup.py')
-rw-r--r-- | numpy/core/setup.py | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/numpy/core/setup.py b/numpy/core/setup.py index 63962ab79..a13480907 100644 --- a/numpy/core/setup.py +++ b/numpy/core/setup.py @@ -422,12 +422,13 @@ def configuration(parent_package='',top_path=None): exec_mod_from_location) from numpy.distutils.system_info import (get_info, blas_opt_info, lapack_opt_info) + from numpy.version import release as is_released config = Configuration('core', parent_package, top_path) local_dir = config.local_path codegen_dir = join(local_dir, 'code_generators') - if is_released(config): + if is_released: warnings.simplefilter('error', MismatchCAPIWarning) # Check whether we have a mismatch between the set C API VERSION and the |