nixpkgs mirror (for testing) github.com/NixOS/nixpkgs
nix
at python-updates 68 lines 1.2 kB view raw
1{ 2 lib, 3 buildPythonPackage, 4 fetchFromGitHub, 5 setuptools, 6 certifi, 7 numpy, 8 sgp4, 9 jplephem, 10 pandas, 11 ipython, 12 matplotlib, 13 assay, 14}: 15 16buildPythonPackage rec { 17 pname = "skyfield"; 18 version = "1.54"; 19 pyproject = true; 20 21 src = fetchFromGitHub { 22 owner = "skyfielders"; 23 repo = "python-skyfield"; 24 rev = version; 25 hash = "sha256-oZEmc8BVqs3eSaqrjyR/wQu1WTLv4A0a/dpEZduCXqk="; 26 }; 27 28 # Fix broken tests on "exotic" platforms. 29 # https://github.com/skyfielders/python-skyfield/issues/582#issuecomment-822033858 30 postPatch = '' 31 substituteInPlace skyfield/tests/test_planetarylib.py \ 32 --replace-fail "if IS_32_BIT" "if True" 33 ''; 34 35 build-system = [ setuptools ]; 36 37 dependencies = [ 38 certifi 39 numpy 40 sgp4 41 jplephem 42 ]; 43 44 nativeCheckInputs = [ 45 pandas 46 ipython 47 matplotlib 48 assay 49 ]; 50 51 checkPhase = '' 52 runHook preCheck 53 54 cd ci 55 assay --batch skyfield.tests 56 57 runHook postCheck 58 ''; 59 60 pythonImportsCheck = [ "skyfield" ]; 61 62 meta = { 63 homepage = "https://github.com/skyfielders/python-skyfield"; 64 description = "Elegant astronomy for Python"; 65 license = lib.licenses.mit; 66 maintainers = with lib.maintainers; [ zane ]; 67 }; 68}