about summary refs log tree commit diff
path: root/nixpkgs/pkgs/development/python-modules/numpy/default.nix
diff options
context:
space:
mode:
authorAlyssa Ross <hi@alyssa.is>2021-04-09 18:28:16 +0000
committerAlyssa Ross <hi@alyssa.is>2021-04-12 18:46:15 +0000
commitfd2e737e0678ee7d8081baef05b305146a2c0034 (patch)
treeac3e9b27576a0382335532d126f9a66d486bc638 /nixpkgs/pkgs/development/python-modules/numpy/default.nix
parentcc207d720b6aa836e256c1ee9842bc739e630a8a (diff)
parent9e377a6ce42dccd9b624ae4ce8f978dc892ba0e2 (diff)
downloadnixlib-fd2e737e0678ee7d8081baef05b305146a2c0034.tar
nixlib-fd2e737e0678ee7d8081baef05b305146a2c0034.tar.gz
nixlib-fd2e737e0678ee7d8081baef05b305146a2c0034.tar.bz2
nixlib-fd2e737e0678ee7d8081baef05b305146a2c0034.tar.lz
nixlib-fd2e737e0678ee7d8081baef05b305146a2c0034.tar.xz
nixlib-fd2e737e0678ee7d8081baef05b305146a2c0034.tar.zst
nixlib-fd2e737e0678ee7d8081baef05b305146a2c0034.zip
Merge remote-tracking branch 'nixpkgs/nixos-unstable'
Diffstat (limited to 'nixpkgs/pkgs/development/python-modules/numpy/default.nix')
-rw-r--r--nixpkgs/pkgs/development/python-modules/numpy/default.nix27
1 files changed, 11 insertions, 16 deletions
diff --git a/nixpkgs/pkgs/development/python-modules/numpy/default.nix b/nixpkgs/pkgs/development/python-modules/numpy/default.nix
index 51eeab3177e2..ed6f80b34a69 100644
--- a/nixpkgs/pkgs/development/python-modules/numpy/default.nix
+++ b/nixpkgs/pkgs/development/python-modules/numpy/default.nix
@@ -4,15 +4,15 @@
 , buildPythonPackage
 , gfortran
 , hypothesis
-, pytest_5
+, pytest
 , blas
 , lapack
 , writeTextFile
 , isPyPy
 , cython
 , setuptoolsBuildHook
-, fetchpatch
- }:
+, pythonOlder
+}:
 
 assert (!blas.isILP64) && (!lapack.isILP64);
 
@@ -40,31 +40,26 @@ let
   };
 in buildPythonPackage rec {
   pname = "numpy";
-  version = "1.19.4";
+  version = "1.20.1";
   format = "pyproject.toml";
+  disabled = pythonOlder "3.7";
 
   src = fetchPypi {
     inherit pname version;
     extension = "zip";
-    sha256 = "141ec3a3300ab89c7f2b0775289954d193cc8edb621ea05f99db9cb181530512";
+    sha256 = "02m6sms6wb4flfg8y4h0msan4y7w7qgfqxhdk21lcabhm2339iiv";
   };
 
-  nativeBuildInputs = [ gfortran cython setuptoolsBuildHook ];
-  buildInputs = [ blas lapack ];
-
-  patches = [
-    # For compatibility with newer pytest
-    (fetchpatch {
-      url = "https://github.com/numpy/numpy/commit/ba315034759fbf91c61bb55390edc86e7b2627f3.patch";
-      sha256 = "F2P5q61CyhqsZfwkLmxb7A9YdE+43FXLbQkSjop2rVY=";
-    })
-  ] ++ lib.optionals python.hasDistutilsCxxPatch [
+  patches = lib.optionals python.hasDistutilsCxxPatch [
     # We patch cpython/distutils to fix https://bugs.python.org/issue1222585
     # Patching of numpy.distutils is needed to prevent it from undoing the
     # patch to distutils.
     ./numpy-distutils-C++.patch
   ];
 
+  nativeBuildInputs = [ gfortran cython setuptoolsBuildHook ];
+  buildInputs = [ blas lapack ];
+
   # we default openblas to build with 64 threads
   # if a machine has more than 64 threads, it will segfault
   # see https://github.com/xianyi/OpenBLAS/issues/2993
@@ -83,7 +78,7 @@ in buildPythonPackage rec {
   doCheck = !isPyPy; # numpy 1.16+ hits a bug in pypy's ctypes, using either numpy or pypy HEAD fixes this (https://github.com/numpy/numpy/issues/13807)
 
   checkInputs = [
-    pytest_5 # pytest 6 will error: "module is already imported: hypothesis"
+    pytest
     hypothesis
   ];