diff options
author | Ricardo Wurmus <rekado@elephly.net> | 2021-11-20 23:40:00 +0100 |
---|---|---|
committer | Ricardo Wurmus <rekado@elephly.net> | 2021-11-21 00:39:09 +0100 |
commit | a22fb2d1644fbaffb737be822ade275b4901a32b (patch) | |
tree | e98b3ca2bf09e56796d9e708e7d278fb13a94683 /gnu | |
parent | 55870e86d9dae6e25cb7723f1196ab9a6aaaef3f (diff) | |
download | guix-a22fb2d1644fbaffb737be822ade275b4901a32b.tar.gz guix-a22fb2d1644fbaffb737be822ade275b4901a32b.zip |
gnu: python-numpy: Alias to python-numpy-1.20.
Numpy 1.20 is required by numba and umap-learn. Attempts to rename numpy 1.20
to allow it to coexist with numpy 1.21 in the same environment have not been
successful.
* gnu/packages/python-xyz.scm (python-numpy): Rename to...
(python-numpy-next): ...this variable.
(python2-numpy): Use python-numpy-next package as parent.
(python-numpy-1.20): Inherit from python-numpy-next.
(python-numpy): New variable pointing to python-numpy-1.20.
(python-numba)[propagated-inputs]: Replace python-numpy-1.20 with
python-numpy.
Diffstat (limited to 'gnu')
-rw-r--r-- | gnu/packages/python-xyz.scm | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index b953f3a7cb..66c32c9f02 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -5271,7 +5271,7 @@ writing C extensions for Python as easy as Python itself.") ;; NOTE: when upgrading numpy please make sure that python-pandas and ;; python-scipy still build, as these three packages are often used together. -(define-public python-numpy +(define-public python-numpy-next (package (name "python-numpy") (version "1.21.3") @@ -5343,7 +5343,7 @@ capabilities.") ;; Numpy 1.16.x are the last versions that support Python 2. (define-public python2-numpy (let ((numpy (package-with-python2 - (strip-python2-variant python-numpy)))) + (strip-python2-variant python-numpy-next)))) (package (inherit numpy) (version "1.16.5") @@ -5359,7 +5359,7 @@ capabilities.") ;; Needed by python-numba, see https://github.com/numba/numba/issues/7176 (define-public python-numpy-1.20 (package - (inherit python-numpy) + (inherit python-numpy-next) (version "1.20.3") (source (origin (method url-fetch) @@ -5372,9 +5372,11 @@ capabilities.") ;; 92 tests fail, many of them because parts of the temp file name ;; accidentally ends up in a comparison. (arguments - (substitute-keyword-arguments (package-arguments python-numpy) + (substitute-keyword-arguments (package-arguments python-numpy-next) ((#:tests? _ #t) #f))))) +(define-public python-numpy python-numpy-1.20) + ;; NOTE: NumPy 1.8 is packaged only for Python 2 because it is of ;; interest only for legacy code going back to NumPy's predecessor ;; Numeric. @@ -22037,7 +22039,7 @@ validation testing and application logic.") (invoke "python3" "-m" "numba.runtests" "-v" "-m")))))))) (propagated-inputs `(("python-llvmlite" ,python-llvmlite) - ("python-numpy" ,python-numpy-1.20) + ("python-numpy" ,python-numpy) ("python-singledispatch" ,python-singledispatch))) (native-inputs ;for tests `(("python-jinja2" ,python-jinja2) |