From 182945f2851d570f868125bbf17a3acc5dcfd84f Mon Sep 17 00:00:00 2001 From: "Robert T. McGibbon" Date: Sun, 27 Dec 2020 19:14:39 -0500 Subject: [PATCH 01/12] python3Packages.pyerfa: init at 1.7.1.1 --- .../python-modules/pyerfa/default.nix | 42 +++++++++++++++++++ pkgs/top-level/python-packages.nix | 2 + 2 files changed, 44 insertions(+) create mode 100644 pkgs/development/python-modules/pyerfa/default.nix diff --git a/pkgs/development/python-modules/pyerfa/default.nix b/pkgs/development/python-modules/pyerfa/default.nix new file mode 100644 index 000000000000..26a61ddca540 --- /dev/null +++ b/pkgs/development/python-modules/pyerfa/default.nix @@ -0,0 +1,42 @@ +{ lib +, buildPythonPackage +, fetchPypi +, isPy3k +, liberfa +, packaging +, numpy +}: + +buildPythonPackage rec { + pname = "pyerfa"; + format = "pyproject"; + version = "1.7.1.1"; + + doCheck = false; + + src = fetchPypi { + inherit pname version; + sha256 = "09i2qcsvxd3q04a5yaf6fwzg79paaslpksinan9d8smj7viql15i"; + }; + + nativeBuildInputs = [ packaging ]; + propagatedBuildInputs = [ liberfa numpy ]; + preBuild = '' + export PYERFA_USE_SYSTEM_LIBERFA=1 + ''; + + meta = with lib; { + description = "Python bindings for ERFA routines"; + longDescription = '' + PyERFA is the Python wrapper for the ERFA library (Essential Routines + for Fundamental Astronomy), a C library containing key algorithms for + astronomy, which is based on the SOFA library published by the + International Astronomical Union (IAU). All C routines are wrapped as + Numpy universal functions, so that they can be called with scalar or + array inputs. + ''; + homepage = "https://github.com/liberfa/pyerfa"; + license = licenses.bsd3; + maintainers = [ maintainers.rmcgibbo ]; + }; +} diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index 440b53aaf2a4..33d255216962 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -5117,6 +5117,8 @@ in { pyepsg = callPackage ../development/python-modules/pyepsg { }; + pyerfa = callPackage ../development/python-modules/pyerfa { }; + pyexcel = callPackage ../development/python-modules/pyexcel { }; pyexcelerator = callPackage ../development/python-modules/pyexcelerator { }; From 7ef5a93fe1a3e69307b316484641fee7caed0ed4 Mon Sep 17 00:00:00 2001 From: "Robert T. McGibbon" Date: Sun, 27 Dec 2020 19:15:59 -0500 Subject: [PATCH 02/12] python3Packages.astropy-extension-helpers: init at 0.1 --- .../astropy-extension-helpers/default.nix | 31 ++++++++++++++ .../permissions.patch | 20 +++++++++ .../extension-helpers/default.nix | 41 ------------------- pkgs/top-level/python-packages.nix | 4 +- 4 files changed, 53 insertions(+), 43 deletions(-) create mode 100644 pkgs/development/python-modules/astropy-extension-helpers/default.nix create mode 100644 pkgs/development/python-modules/astropy-extension-helpers/permissions.patch delete mode 100644 pkgs/development/python-modules/extension-helpers/default.nix diff --git a/pkgs/development/python-modules/astropy-extension-helpers/default.nix b/pkgs/development/python-modules/astropy-extension-helpers/default.nix new file mode 100644 index 000000000000..bd9dca338fcd --- /dev/null +++ b/pkgs/development/python-modules/astropy-extension-helpers/default.nix @@ -0,0 +1,31 @@ +{ lib +, buildPythonPackage +, fetchPypi +, pytestCheckHook +}: + +buildPythonPackage rec { + pname = "extension-helpers"; + version = "0.1"; + format = "pyproject"; + + src = fetchPypi { + inherit pname version; + sha256 = "10iqjzmya2h4sk765dlm1pbqypwlqyh8rw59a5m9i63d3klnz2mc"; + }; + + patches = [ ./permissions.patch ]; + + checkInputs = [ pytestCheckHook ]; + + pythonImportsCheck = [ + "extension_helpers" + ]; + + meta = with lib; { + description = "Utilities for building and installing packages in the Astropy ecosystem"; + homepage = "https://github.com/astropy/extension-helpers"; + license = licenses.bsd3; + maintainers = [ maintainers.rmcgibbo ]; + }; +} diff --git a/pkgs/development/python-modules/astropy-extension-helpers/permissions.patch b/pkgs/development/python-modules/astropy-extension-helpers/permissions.patch new file mode 100644 index 000000000000..cef74b336034 --- /dev/null +++ b/pkgs/development/python-modules/astropy-extension-helpers/permissions.patch @@ -0,0 +1,20 @@ +diff --git a/extension_helpers/_setup_helpers.py b/extension_helpers/_setup_helpers.py +index ec3e547..e2419f7 100644 +--- a/extension_helpers/_setup_helpers.py ++++ b/extension_helpers/_setup_helpers.py +@@ -79,8 +79,13 @@ def get_extensions(srcdir='.'): + if len(ext_modules) > 0: + main_package_dir = min(packages, key=len) + src_path = os.path.join(os.path.dirname(__file__), 'src') +- shutil.copy(os.path.join(src_path, 'compiler.c'), +- os.path.join(srcdir, main_package_dir, '_compiler.c')) ++ a = os.path.join(src_path, 'compiler.c') ++ b = os.path.join(srcdir, main_package_dir, '_compiler.c') ++ try: ++ os.unlink(b) ++ except OSError: ++ pass ++ shutil.copy(a, b) + ext = Extension(main_package_dir + '.compiler_version', + [os.path.join(main_package_dir, '_compiler.c')]) + ext_modules.append(ext) diff --git a/pkgs/development/python-modules/extension-helpers/default.nix b/pkgs/development/python-modules/extension-helpers/default.nix deleted file mode 100644 index 0c23a69a89cd..000000000000 --- a/pkgs/development/python-modules/extension-helpers/default.nix +++ /dev/null @@ -1,41 +0,0 @@ -{ lib -, buildPythonPackage -, fetchPypi -, isPy27 -, pytestCheckHook -, setuptools_scm -}: - -buildPythonPackage rec { - pname = "extension-helpers"; - version = "0.1"; - disabled = isPy27; - - src = fetchPypi { - inherit pname version; - sha256 = "10iqjzmya2h4sk765dlm1pbqypwlqyh8rw59a5m9i63d3klnz2mc"; - }; - - nativeBuildInputs = [ - setuptools_scm - ]; - - propagatedBuildInputs = [ - pytestCheckHook - ]; - - # avoid importing local module - preCheck = '' - cd extension_helpers - ''; - - # assumes setup.py is in pwd - disabledTests = [ "compiler_module" ]; - - meta = with lib; { - description = "Helpers to assist with building packages with compiled C/Cython extensions"; - homepage = "https://github.com/astropy/extension-helpers"; - license = licenses.bsd3; - maintainers = [ ]; - }; -} diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index 33d255216962..10bb3c528573 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -421,6 +421,8 @@ in { astropy-helpers = callPackage ../development/python-modules/astropy-helpers { }; + astropy-extension-helpers = callPackage ../development/python-modules/astropy-extension-helpers { }; + astroquery = callPackage ../development/python-modules/astroquery { }; asttokens = callPackage ../development/python-modules/asttokens { }; @@ -1997,8 +1999,6 @@ in { exifread = callPackage ../development/python-modules/exifread { }; - extension-helpers = callPackage ../development/python-modules/extension-helpers { }; - extras = callPackage ../development/python-modules/extras { }; eyeD3 = callPackage ../development/python-modules/eyed3 { }; From 8df2e7698436e684a41349545f5302a729b706b6 Mon Sep 17 00:00:00 2001 From: "Robert T. McGibbon" Date: Sun, 27 Dec 2020 19:16:28 -0500 Subject: [PATCH 03/12] python3Packages.astropy: unbreak --- .../python-modules/astropy/default.nix | 26 +++++++++---------- 1 file changed, 13 insertions(+), 13 deletions(-) diff --git a/pkgs/development/python-modules/astropy/default.nix b/pkgs/development/python-modules/astropy/default.nix index 2fe59e53d9c1..9ffcba63954b 100644 --- a/pkgs/development/python-modules/astropy/default.nix +++ b/pkgs/development/python-modules/astropy/default.nix @@ -1,5 +1,6 @@ { lib , fetchPypi +, setuptools_scm , buildPythonPackage , isPy3k , cython @@ -8,11 +9,14 @@ , pytest , pytest-astropy , astropy-helpers +, astropy-extension-helpers +, pyerfa }: buildPythonPackage rec { pname = "astropy"; version = "4.2"; + format = "pyproject"; disabled = !isPy3k; # according to setup.py @@ -21,15 +25,12 @@ buildPythonPackage rec { sha256 = "2c194f8a429b8399de64a413a06881ea49f0525cabaa2d78fc132b9e970adc6a"; }; - nativeBuildInputs = [ astropy-helpers cython jinja2 ]; - - propagatedBuildInputs = [ numpy pytest ]; # yes it really has pytest in install_requires - + nativeBuildInputs = [ setuptools_scm astropy-helpers astropy-extension-helpers cython jinja2 ]; + propagatedBuildInputs = [ numpy pyerfa ]; checkInputs = [ pytest pytest-astropy ]; - # Disable automatic update of the astropy-helper module - postPatch = '' - substituteInPlace setup.cfg --replace "auto_use = True" "auto_use = False" + preBuild = '' + export SETUPTOOLS_SCM_PRETEND_VERSION="${version}" ''; # Tests must be run from the build directory. astropy/samp tests @@ -42,15 +43,14 @@ buildPythonPackage rec { ''; # 368 failed, 10889 passed, 978 skipped, 69 xfailed in 196.24s + # doCheck = false; doCheck = false; - meta = { + meta = with lib; { description = "Astronomy/Astrophysics library for Python"; homepage = "https://www.astropy.org"; - license = lib.licenses.bsd3; - platforms = lib.platforms.all; - maintainers = with lib.maintainers; [ kentjames ]; + license = licenses.bsd3; + platforms = platforms.all; + maintainers = [ maintainers.kentjames ]; }; } - - From 545350f147daaa04485e22c0dfe1e725a1cc5cb2 Mon Sep 17 00:00:00 2001 From: "Robert T. McGibbon" Date: Mon, 28 Dec 2020 13:08:50 -0500 Subject: [PATCH 04/12] python3Packages.astroquery: unbreak --- pkgs/development/python-modules/astroquery/default.nix | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/pkgs/development/python-modules/astroquery/default.nix b/pkgs/development/python-modules/astroquery/default.nix index e82dca3e9553..f7764149a663 100644 --- a/pkgs/development/python-modules/astroquery/default.nix +++ b/pkgs/development/python-modules/astroquery/default.nix @@ -15,6 +15,7 @@ buildPythonPackage rec { pname = "astroquery"; version = "0.4.1"; + format = "pyproject"; src = fetchPypi { inherit pname version; @@ -31,11 +32,6 @@ buildPythonPackage rec { doCheck = false; checkInputs = [ pytest pytest-astropy ]; - # Disable automatic update of the astropy-helper module - postPatch = '' - substituteInPlace setup.cfg --replace "auto_use = True" "auto_use = False" - ''; - # Tests must be run in the build directory. The tests create files # in $HOME/.astropy so we need to set HOME to $TMPDIR. checkPhase = '' From 39df1e526dc17f4a05a1619de0f5dcfefb9282a2 Mon Sep 17 00:00:00 2001 From: "Robert T. McGibbon" Date: Mon, 28 Dec 2020 13:23:44 -0500 Subject: [PATCH 05/12] python3Packages.drms: unbreak --- pkgs/development/python-modules/drms/default.nix | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/pkgs/development/python-modules/drms/default.nix b/pkgs/development/python-modules/drms/default.nix index 561ec9a7a98e..613d2444d73c 100644 --- a/pkgs/development/python-modules/drms/default.nix +++ b/pkgs/development/python-modules/drms/default.nix @@ -4,13 +4,15 @@ , numpy , pandas , six -, pytest -, python +, astropy +, pytestCheckHook +, pytest-doctestplus }: buildPythonPackage rec { pname = "drms"; version = "0.6.0"; + format = "pyproject"; src = fetchPypi { inherit pname version; @@ -24,13 +26,11 @@ buildPythonPackage rec { ]; checkInputs = [ - pytest + astropy + pytestCheckHook + pytest-doctestplus ]; - checkPhase = '' - ${python.interpreter} -m drms.tests - ''; - meta = with lib; { description = "Access HMI, AIA and MDI data with Python"; homepage = "https://github.com/sunpy/drms"; From 343015526efa16bfdbe294479b4deb83f986e3b7 Mon Sep 17 00:00:00 2001 From: "Robert T. McGibbon" Date: Mon, 28 Dec 2020 13:33:33 -0500 Subject: [PATCH 06/12] python3Packages.asdf: unbreak --- pkgs/development/python-modules/asdf/default.nix | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) diff --git a/pkgs/development/python-modules/asdf/default.nix b/pkgs/development/python-modules/asdf/default.nix index 474329ed0b7d..4006a034d48d 100644 --- a/pkgs/development/python-modules/asdf/default.nix +++ b/pkgs/development/python-modules/asdf/default.nix @@ -17,18 +17,13 @@ buildPythonPackage rec { pname = "asdf"; version = "2.7.1"; disabled = isPy27; + format = "pyproject"; src = fetchPypi { inherit pname version; sha256 = "4ba2e31cb24b974a10dfae3edee23db2e6bea2d00608604d062366aa3af6e81a"; }; - postPatch = '' - substituteInPlace setup.cfg \ - --replace "semantic_version>=2.3.1,<=2.6.0" "semantic_version>=2.3.1" \ - --replace "doctest_plus = enabled" "" - ''; - checkInputs = [ pytest-astropy astropy @@ -45,7 +40,7 @@ buildPythonPackage rec { ]; checkPhase = '' - pytest + PY_IGNORE_IMPORTMISMATCH=1 pytest ''; meta = with lib; { From 0cdd25eba30d1ba3a7fe0ee67b3ea91935998b14 Mon Sep 17 00:00:00 2001 From: "Robert T. McGibbon" Date: Mon, 28 Dec 2020 13:49:17 -0500 Subject: [PATCH 07/12] python3Packages.sunpy: 1.0.6 -> 2.0.6 --- .../python-modules/sunpy/default.nix | 25 ++++++++----------- 1 file changed, 11 insertions(+), 14 deletions(-) diff --git a/pkgs/development/python-modules/sunpy/default.nix b/pkgs/development/python-modules/sunpy/default.nix index 6830c7c13430..6a455ce49ebe 100644 --- a/pkgs/development/python-modules/sunpy/default.nix +++ b/pkgs/development/python-modules/sunpy/default.nix @@ -1,12 +1,12 @@ { stdenv , lib , buildPythonPackage -, fetchFromGitHub +, fetchPypi , pythonOlder - , asdf , astropy , astropy-helpers +, astropy-extension-helpers , beautifulsoup4 , drms , glymur @@ -29,16 +29,18 @@ buildPythonPackage rec { pname = "sunpy"; - version = "1.0.6"; + version = "2.0.6"; disabled = pythonOlder "3.6"; - src = fetchFromGitHub { - owner = "sunpy"; - repo = pname; - rev = "v${version}"; - sha256 = "0j2yfhfxgi95rig8cfp9lvszb7694gq90jvs0xrb472hwnzgh2sk"; + src = fetchPypi { + inherit pname version; + sha256 = "109flghca42yhsm2w5xicqhyx1mc8c3vlwvadbn65fz3lhysqj67"; }; + nativeBuildInputs = [ + astropy-extension-helpers + ]; + propagatedBuildInputs = [ numpy scipy @@ -66,16 +68,11 @@ buildPythonPackage rec { pytest-mock ]; - preBuild = '' - export SETUPTOOLS_SCM_PRETEND_VERSION="${version}" - export HOME=$(mktemp -d) - ''; - # darwin has write permission issues doCheck = stdenv.isLinux; # ignore documentation tests checkPhase = '' - pytest sunpy -k 'not rst' + PY_IGNORE_IMPORTMISMATCH=1 HOME=$(mktemp -d) pytest sunpy -k 'not rst' ''; meta = with lib; { From f5dc54e7b6d6df29aab5812e3b985b9d2aeadada Mon Sep 17 00:00:00 2001 From: "Robert T. McGibbon" Date: Mon, 28 Dec 2020 14:27:06 -0500 Subject: [PATCH 08/12] python3Packages.reproject: unbreak --- .../python-modules/reproject/default.nix | 19 ++++++++++--------- 1 file changed, 10 insertions(+), 9 deletions(-) diff --git a/pkgs/development/python-modules/reproject/default.nix b/pkgs/development/python-modules/reproject/default.nix index ccc76734461e..8448f55f9583 100644 --- a/pkgs/development/python-modules/reproject/default.nix +++ b/pkgs/development/python-modules/reproject/default.nix @@ -6,7 +6,7 @@ , astropy , astropy-healpix , astropy-helpers -, extension-helpers +, astropy-extension-helpers , scipy , pytest , pytest-astropy @@ -23,15 +23,16 @@ buildPythonPackage rec { sha256 = "1jsc3ad518vyys5987fr1achq8qvnz8rm80zp5an9qxlwr4zmh4m"; }; - propagatedBuildInputs = [ numpy astropy astropy-healpix astropy-helpers scipy ]; - - nativeBuildInputs = [ astropy-helpers cython extension-helpers setuptools_scm ]; - - # Disable automatic update of the astropy-helper module - postPatch = '' - substituteInPlace setup.cfg --replace "auto_use = True" "auto_use = False" - ''; + patches = [ (fetchpatch { + # Can be removed in next release after 0.7.1 + # See https://github.com/astropy/reproject/issues/246 + url = "https://github.com/astropy/reproject/pull/243.patch"; + sha256 = "0dq3ii39hsrks0b9v306dlqf07dx0hqad8rwajmzw6rfda9m3c2a"; + }) + ]; + propagatedBuildInputs = [ numpy astropy aqstropy-healpix astropy-helpers scipy ]; + nativeBuildInputs = [ astropy-helpers cyqthon astropy-extension-helpers setuptools_scm ]; checkInputs = [ pytest pytest-astropy ]; # Tests must be run in the build directory From 7a468478bce26e7c65abbee16a4bb3dbecd33c1d Mon Sep 17 00:00:00 2001 From: "Robert T. McGibbon" Date: Mon, 28 Dec 2020 14:50:25 -0500 Subject: [PATCH 09/12] python3Packages.aplpy: unbreak --- .../python-modules/aplpy/default.nix | 21 +++++++++++-------- 1 file changed, 12 insertions(+), 9 deletions(-) diff --git a/pkgs/development/python-modules/aplpy/default.nix b/pkgs/development/python-modules/aplpy/default.nix index a6eedb3b7a4b..e253c610c214 100644 --- a/pkgs/development/python-modules/aplpy/default.nix +++ b/pkgs/development/python-modules/aplpy/default.nix @@ -1,6 +1,7 @@ { lib , buildPythonPackage , fetchPypi +, fetchpatch , numpy , astropy , astropy-helpers @@ -18,6 +19,7 @@ buildPythonPackage rec { pname = "aplpy"; version = "2.0.3"; + format = "pyproject"; src = fetchPypi { pname = "APLpy"; @@ -25,6 +27,15 @@ buildPythonPackage rec { sha256 = "239f3d83635ca4251536aeb577df7c60df77fc4d658097b92094719739aec3f3"; }; + patches = [ (fetchpatch { + # Can be removed in next release after 2.0.3 + url = "https://github.com/aplpy/aplpy/pull/448.patch"; + sha256 = "1pnzh7ykjc8hwahzbzyryrzv5a8fddgd1bmzbhagkrn6lmvhhpvq"; + excludes = [ "tox.ini" "azure-pipelines.yml" ".circleci/config.yml" "MANIFEST.in" ".gitignore" + "setup.cfg" "appveyor.yml" "readthedocs.yml" "CHANGES.rst" ".gitmodules" ".travis.yml" "astropy_helpers" ]; + }) + ]; + propagatedBuildInputs = [ numpy astropy @@ -38,18 +49,10 @@ buildPythonPackage rec { ]; nativeBuildInputs = [ astropy-helpers ]; - checkInputs = [ pytest pytest-astropy ]; - # Disable automatic update of the astropy-helper module - postPatch = '' - substituteInPlace setup.cfg --replace "auto_use = True" "auto_use = False" - ''; - - # Tests must be run in the build directory checkPhase = '' - cd build/lib - pytest + OPENMP_EXPECTED=0 pytest aplpy ''; meta = with lib; { From edbf7a37b13f136928f243c4f176bc0c4a519c31 Mon Sep 17 00:00:00 2001 From: "Robert T. McGibbon" Date: Mon, 28 Dec 2020 14:50:43 -0500 Subject: [PATCH 10/12] python3Packages.reproject: unbreak --- pkgs/development/python-modules/reproject/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/development/python-modules/reproject/default.nix b/pkgs/development/python-modules/reproject/default.nix index 8448f55f9583..98bed15cfa06 100644 --- a/pkgs/development/python-modules/reproject/default.nix +++ b/pkgs/development/python-modules/reproject/default.nix @@ -31,8 +31,8 @@ buildPythonPackage rec { }) ]; - propagatedBuildInputs = [ numpy astropy aqstropy-healpix astropy-helpers scipy ]; - nativeBuildInputs = [ astropy-helpers cyqthon astropy-extension-helpers setuptools_scm ]; + propagatedBuildInputs = [ numpy astropy astropy-healpix astropy-helpers scipy ]; + nativeBuildInputs = [ astropy-helpers cython astropy-extension-helpers setuptools_scm ]; checkInputs = [ pytest pytest-astropy ]; # Tests must be run in the build directory From 0bba94bb4c7577a6f2b8056cf8bc8651b8b130ee Mon Sep 17 00:00:00 2001 From: "Robert T. McGibbon" Date: Mon, 28 Dec 2020 14:54:14 -0500 Subject: [PATCH 11/12] python3Packages.spectral-cube: 0.4.5 -> 0.5.0 --- .../python-modules/spectral-cube/default.nix | 28 ++++++------------- 1 file changed, 9 insertions(+), 19 deletions(-) diff --git a/pkgs/development/python-modules/spectral-cube/default.nix b/pkgs/development/python-modules/spectral-cube/default.nix index b0b3e4b8f65f..d2f79c183480 100644 --- a/pkgs/development/python-modules/spectral-cube/default.nix +++ b/pkgs/development/python-modules/spectral-cube/default.nix @@ -1,7 +1,8 @@ { lib -, fetchFromGitHub +, fetchPypi , buildPythonPackage , aplpy +, joblib , astropy , radio_beam , pytest @@ -11,31 +12,20 @@ buildPythonPackage rec { pname = "spectral-cube"; - version = "0.4.5"; + version = "0.5.0"; + format = "pyproject"; - # Fetch from GitHub instead of PyPi, as 0.4.5 isn't available in PyPi - src = fetchFromGitHub { - owner = "radio-astro-tools"; - repo = pname; - rev = "v${version}"; - sha256 = "1xc1m6vpl0bm600fx9vypa7zcvwg7yvhgn0w89y6v9d1vl0qcs7z"; + src = fetchPypi { + inherit pname version; + sha256 = "17zisr26syfb8kn89xj17lrdycm0hsmy5yp5zrn236wgd8rjriki"; }; - propagatedBuildInputs = [ astropy radio_beam ]; - nativeBuildInputs = [ astropy-helpers ]; - + propagatedBuildInputs = [ astropy radio_beam joblib ]; checkInputs = [ aplpy pytest pytest-astropy ]; - # Disable automatic update of the astropy-helper module - postPatch = '' - substituteInPlace setup.cfg --replace "auto_use = True" "auto_use = False" - ''; - - # Tests must be run in the build directory checkPhase = '' - cd build/lib - pytest + pytest spectral_cube ''; meta = { From d7ca8099bfa09e89914cfa4ba99adf41ccca25d6 Mon Sep 17 00:00:00 2001 From: "Robert T. McGibbon" Date: Mon, 28 Dec 2020 15:10:19 -0500 Subject: [PATCH 12/12] python3Packages.pytest-astropy-header: unbreak --- .../pytest-astropy-header/default.nix | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/pkgs/development/python-modules/pytest-astropy-header/default.nix b/pkgs/development/python-modules/pytest-astropy-header/default.nix index 05c6135a4b9d..4b40280ed700 100644 --- a/pkgs/development/python-modules/pytest-astropy-header/default.nix +++ b/pkgs/development/python-modules/pytest-astropy-header/default.nix @@ -1,21 +1,36 @@ { lib , buildPythonPackage , fetchPypi +, fetchpatch , pytest , pytestcov , pytestCheckHook , numpy , astropy +, scipy +, h5py +, scikitimage }: buildPythonPackage rec { pname = "pytest-astropy-header"; version = "0.1.2"; + format = "pyproject"; src = fetchPypi { inherit pname version; sha256 = "1y87agr324p6x5gvhziymxjlw54pyn4gqnd49papbl941djpkp5g"; }; + patches = [ (fetchpatch { + url = "https://github.com/astropy/pytest-astropy-header/pull/16.patch"; + sha256 = "11ln63zq0kgsdx1jw3prlzpcdbxmc99p9cwr18s0x6apy0k6df31"; + }) + (fetchpatch { + url = "https://github.com/astropy/pytest-astropy-header/pull/29.patch"; + sha256 = "18l434c926r5z1iq3b6lpnp0lrssszars9y1y9hs6216r60jgjpl"; + }) + ]; + propagatedBuildInputs = [ pytest @@ -25,6 +40,9 @@ buildPythonPackage rec { pytestCheckHook pytestcov numpy + scipy + h5py + scikitimage astropy ];