Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
at 24.05-beta 62 lines 1.2 kB view raw
1{ 2 lib, 3 stdenv, 4 buildPythonPackage, 5 fetchPypi, 6 numpy, 7 astropy, 8 astropy-extension-helpers, 9 setuptools, 10 setuptools-scm, 11 pytestCheckHook, 12 pytest-doctestplus, 13 hypothesis, 14}: 15 16buildPythonPackage rec { 17 pname = "astropy-healpix"; 18 version = "1.0.3"; 19 pyproject = true; 20 21 src = fetchPypi { 22 inherit version; 23 pname = lib.replaceStrings [ "-" ] [ "_" ] pname; 24 hash = "sha256-3l0qfsl7FnBFBmlx8loVDR5AYfBxWb4jZJY02zbnl0Y="; 25 }; 26 27 postPatch = '' 28 substituteInPlace pyproject.toml --replace "numpy>=2.0.0rc1" "numpy" 29 ''; 30 31 nativeBuildInputs = [ 32 astropy-extension-helpers 33 numpy 34 setuptools 35 setuptools-scm 36 ]; 37 38 propagatedBuildInputs = [ 39 numpy 40 astropy 41 ]; 42 43 nativeCheckInputs = [ 44 pytestCheckHook 45 pytest-doctestplus 46 hypothesis 47 ]; 48 49 disabledTests = lib.optional (!stdenv.hostPlatform.isDarwin) "test_interpolate_bilinear_skycoord"; 50 51 # tests must be run in the build directory 52 preCheck = '' 53 cd build/lib* 54 ''; 55 56 meta = with lib; { 57 description = "BSD-licensed HEALPix for Astropy"; 58 homepage = "https://github.com/astropy/astropy-healpix"; 59 license = licenses.bsd3; 60 maintainers = [ maintainers.smaret ]; 61 }; 62}