1{ 2 lib, 3 fetchPypi, 4 fetchpatch2, 5 buildPythonPackage, 6 setuptools-scm, 7 astropy, 8 numpy, 9 matplotlib, 10 scipy, 11 six, 12 pytestCheckHook, 13 pytest-astropy, 14}: 15 16buildPythonPackage rec { 17 pname = "radio-beam"; 18 version = "0.3.7"; 19 pyproject = true; 20 21 src = fetchPypi { 22 inherit pname version; 23 hash = "sha256-7AFkuuYLzibwwgz6zrFw0fBXCnGLzdm4OgT+Chve5jU="; 24 }; 25 26 # Fix distutils deprecation in Python 3.12. See: 27 # https://github.com/radio-astro-tools/radio-beam/pull/124 28 patches = [ 29 (fetchpatch2 { 30 url = "https://github.com/radio-astro-tools/radio-beam/commit/1eb0216c8d7f5a4494d8d1fe8c79b48425a9c491.patch"; 31 hash = "sha256-kTJF/cnkJCjJI2psvs+4MWFn/+b8TvUWjdfYu5ot0XU="; 32 }) 33 ]; 34 35 nativeBuildInputs = [ setuptools-scm ]; 36 37 propagatedBuildInputs = [ 38 astropy 39 numpy 40 scipy 41 six 42 ]; 43 44 nativeCheckInputs = [ 45 pytestCheckHook 46 matplotlib 47 pytest-astropy 48 ]; 49 50 pythonImportsCheck = [ "radio_beam" ]; 51 52 meta = with lib; { 53 description = "Tools for Beam IO and Manipulation"; 54 homepage = "http://radio-astro-tools.github.io"; 55 changelog = "https://github.com/radio-astro-tools/radio-beam/releases/tag/v${version}"; 56 license = licenses.bsd3; 57 maintainers = with maintainers; [ smaret ]; 58 }; 59}