Merge pull request #194642 from smaret/fix-spectral-cube-deps

This commit is contained in:
Sandro 2022-10-11 20:29:24 +02:00 committed by GitHub
commit 723a0b42d7
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 16 additions and 13 deletions

View file

@ -13,15 +13,15 @@
buildPythonPackage rec {
pname = "pyregion";
version = "2.0";
version = "2.1.1";
# pypi src contains cython-produced .c files which don't compile
# with python3.9
src = fetchFromGitHub {
owner = "astropy";
repo = pname;
rev = version;
sha256 = "1izar7z606czcyws9s8bjbpb1xhqshpv5009rlpc92hciw7jv4kg";
rev = "v${version}";
sha256 = "sha256-xo+XbBJ2HKql9rd7Ma84JofRg8M4u6vmz44Qo8JhEBc=";
};
propagatedBuildInputs = [
@ -30,12 +30,16 @@ buildPythonPackage rec {
astropy
];
# Upstream patch needed for the test to pass
# Upstream patches needed for the tests to pass
# See https://github.com/astropy/pyregion/pull/157/
patches = [
(fetchpatch {
name = "conftest-astropy-3-fix.patch";
url = "https://github.com/astropy/pyregion/pull/136.patch";
sha256 = "13yxjxiqnhjy9gh24hvv6pnwx7qic2mcx3ccr1igjrc3f881d59m";
url = "https://github.com/astropy/pyregion/pull/157/commits/082649730d353a0d0c0ee9619be1aa501aabba62.patch";
sha256 = "sha256-4mHZt3S29ZfK+QKavm6DLBwVxGl/ga7W7GEcQ5ewxuo=";
})
(fetchpatch {
url = "https://github.com/astropy/pyregion/pull/157/commits/c448a465dd56887979da62aec6138fc89bb37b19.patch";
sha256 = "sha256-GEtvScmVbAdE4E5Xx0hNOPommvzcnJ3jNZpBmY3PbyE=";
})
];

View file

@ -2,7 +2,6 @@
, astropy
, astropy-extension-helpers
, astropy-healpix
, astropy-helpers
, buildPythonPackage
, cython
, fetchPypi
@ -28,7 +27,6 @@ buildPythonPackage rec {
nativeBuildInputs = [
astropy-extension-helpers
astropy-helpers
cython
setuptools-scm
];
@ -36,7 +34,6 @@ buildPythonPackage rec {
propagatedBuildInputs = [
astropy
astropy-healpix
astropy-helpers
numpy
scipy
];
@ -46,9 +43,11 @@ buildPythonPackage rec {
pytestCheckHook
];
preCheck = ''
cd build/lib*
'';
pytestFlagsArray = [
"build/lib*"
# Avoid failure due to user warning: Distutils was imported before Setuptools
"-p no:warnings"
];
pythonImportsCheck = [
"reproject"