nixpkgs/pkgs/development/python-modules/aplpy/default.nix

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

90 lines
1.7 KiB
Nix
Raw Normal View History

2019-02-13 16:22:16 +01:00
{
lib,
astropy,
buildPythonPackage,
fetchpatch,
fetchPypi,
2019-02-13 16:22:16 +01:00
matplotlib,
numpy,
pillow,
2019-02-13 16:22:16 +01:00
pyavm,
pyregion,
pytest-astropy,
pytestCheckHook,
pythonOlder,
reproject,
scikit-image,
2023-08-04 17:05:43 -07:00
setuptools,
setuptools-scm,
2019-02-13 16:22:16 +01:00
shapely,
2023-08-04 17:05:43 -07:00
wheel,
2019-02-13 16:22:16 +01:00
}:
buildPythonPackage rec {
pname = "aplpy";
2022-04-01 19:52:18 +11:00
version = "2.1.0";
2020-12-28 14:50:25 -05:00
format = "pyproject";
2019-02-13 16:22:16 +01:00
disabled = pythonOlder "3.6";
2019-02-13 16:22:16 +01:00
src = fetchPypi {
2022-04-01 19:52:18 +11:00
pname = "aplpy";
2019-02-13 16:22:16 +01:00
inherit version;
hash = "sha256-KCdmBwQWt7IfHsjq7pWlbSISEpfQZDyt+SQSTDaUCV4=";
2019-02-13 16:22:16 +01:00
};
# Fix build with Astropy 6 and Python 3.12.
patches = [
# https://github.com/aplpy/aplpy/pull/496
(fetchpatch {
url = "https://github.com/aplpy/aplpy/commit/d232a4984bc6a83ec86dfdc3ab3bc1b05de44c48.patch";
hash = "sha256-jGUTzIrVdGNPy0BV8w46jzz045fDXBisiwIn90bn7oY=";
})
# https://github.com/aplpy/aplpy/pull/497
(fetchpatch {
url = "https://github.com/aplpy/aplpy/commit/468be394970b39f1aaa6debef51eb674e2dd86d8.patch";
hash = "sha256-/ovLrFOKb3RQ8TZSviuOV6EYNgz0gtrhVWZLFJBrzFg=";
})
];
nativeBuildInputs = [
2023-08-04 17:05:43 -07:00
setuptools
setuptools-scm
wheel
];
2019-02-13 16:22:16 +01:00
propagatedBuildInputs = [
astropy
matplotlib
numpy
pillow
2019-02-13 16:22:16 +01:00
pyavm
pyregion
reproject
scikit-image
2019-02-13 16:22:16 +01:00
shapely
];
nativeCheckInputs = [
pytest-astropy
pytestCheckHook
];
2019-07-23 12:50:21 +02:00
preCheck = ''
OPENMP_EXPECTED=0
2019-07-23 12:50:21 +02:00
'';
pythonImportsCheck = [ "aplpy" ];
2019-02-13 16:22:16 +01:00
meta = with lib; {
description = "Astronomical Plotting Library in Python";
homepage = "http://aplpy.github.io";
2019-02-13 16:22:16 +01:00
license = licenses.mit;
maintainers = with maintainers; [ smaret ];
# Tests fail due to expired matplotlib deprecations:
#
# > (`matplotlib.cm' has no attribute 'get_cmap'`)
broken = true;
2019-02-13 16:22:16 +01:00
};
}