2020-04-24 23:36:52 +00:00
|
|
|
{ lib
|
|
|
|
, astropy
|
2022-06-16 17:23:12 +00:00
|
|
|
, astropy-extension-helpers
|
2020-04-24 23:36:52 +00:00
|
|
|
, astropy-healpix
|
2022-06-16 17:23:12 +00:00
|
|
|
, buildPythonPackage
|
|
|
|
, cython
|
|
|
|
, fetchPypi
|
|
|
|
, numpy
|
2023-10-09 19:29:22 +00:00
|
|
|
, oldest-supported-numpy
|
2020-04-24 23:36:52 +00:00
|
|
|
, pytest-astropy
|
2022-06-16 17:23:12 +00:00
|
|
|
, pytestCheckHook
|
|
|
|
, pythonOlder
|
|
|
|
, scipy
|
2021-06-04 09:07:49 +00:00
|
|
|
, setuptools-scm
|
2020-04-24 23:36:52 +00:00
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "reproject";
|
2023-03-04 12:14:45 +00:00
|
|
|
version = "0.10.0";
|
|
|
|
format = "pyproject";
|
2022-06-16 17:23:12 +00:00
|
|
|
|
2023-03-04 12:14:45 +00:00
|
|
|
disabled = pythonOlder "3.8";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
src = fetchPypi {
|
|
|
|
inherit pname version;
|
2023-03-04 12:14:45 +00:00
|
|
|
hash = "sha256-OKxPPKcVVrEVUGR8Zaphn7ur9HOuqQKa9gnMo2RQQME=";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
2023-10-09 19:29:22 +00:00
|
|
|
postPatch = ''
|
|
|
|
substituteInPlace pyproject.toml \
|
|
|
|
--replace "cython==" "cython>="
|
|
|
|
'';
|
|
|
|
|
2022-06-16 17:23:12 +00:00
|
|
|
nativeBuildInputs = [
|
|
|
|
astropy-extension-helpers
|
|
|
|
cython
|
2023-10-09 19:29:22 +00:00
|
|
|
numpy
|
|
|
|
oldest-supported-numpy
|
2022-06-16 17:23:12 +00:00
|
|
|
setuptools-scm
|
2021-01-05 17:05:55 +00:00
|
|
|
];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2022-06-16 17:23:12 +00:00
|
|
|
propagatedBuildInputs = [
|
|
|
|
astropy
|
|
|
|
astropy-healpix
|
|
|
|
numpy
|
|
|
|
scipy
|
|
|
|
];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2023-02-02 18:25:31 +00:00
|
|
|
nativeCheckInputs = [
|
2022-06-16 17:23:12 +00:00
|
|
|
pytest-astropy
|
|
|
|
pytestCheckHook
|
|
|
|
];
|
|
|
|
|
2022-10-21 18:38:19 +00:00
|
|
|
pytestFlagsArray = [
|
|
|
|
"build/lib*"
|
|
|
|
# Avoid failure due to user warning: Distutils was imported before Setuptools
|
|
|
|
"-p no:warnings"
|
2023-03-04 12:14:45 +00:00
|
|
|
# Uses network
|
|
|
|
"--ignore build/lib*/reproject/interpolation/"
|
2022-10-21 18:38:19 +00:00
|
|
|
];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2022-06-16 17:23:12 +00:00
|
|
|
pythonImportsCheck = [
|
|
|
|
"reproject"
|
|
|
|
];
|
|
|
|
|
2020-04-24 23:36:52 +00:00
|
|
|
meta = with lib; {
|
|
|
|
description = "Reproject astronomical images";
|
|
|
|
homepage = "https://reproject.readthedocs.io";
|
|
|
|
license = licenses.bsd3;
|
2022-06-16 17:23:12 +00:00
|
|
|
maintainers = with maintainers; [ smaret ];
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
}
|