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

65 lines
1.2 KiB
Nix

{
lib,
buildPythonPackage,
fetchFromGitHub,
# build-system
setuptools,
setuptools-scm,
# dependencies
numba,
numpy,
scipy,
# tests
dask,
pytest-cov-stub,
pytestCheckHook,
}:
buildPythonPackage rec {
pname = "sparse";
version = "0.15.5";
pyproject = true;
src = fetchFromGitHub {
owner = "pydata";
repo = "sparse";
tag = version;
hash = "sha256-W4rcq7G/bQsT9oTLieOzWNst5LnIAelRMbm+uUPeQgs=";
};
build-system = [
setuptools
setuptools-scm
];
dependencies = [
numba
numpy
scipy
];
nativeCheckInputs = [
dask
pytest-cov-stub
pytestCheckHook
];
pythonImportsCheck = [ "sparse" ];
meta = {
description = "Sparse n-dimensional arrays computations";
homepage = "https://sparse.pydata.org/";
changelog = "https://sparse.pydata.org/en/stable/changelog.html";
downloadPage = "https://github.com/pydata/sparse/releases/tag/${version}";
license = lib.licenses.bsd3;
maintainers = with lib.maintainers; [ GaetanLepage ];
badPlatforms = [
# Most tests fail with: Fatal Python error: Segmentation fault
# numba/typed/typedlist.py", line 344 in append
"aarch64-linux"
];
};
}