1{ lib 2, buildPythonPackage 3, fetchPypi 4, fetchpatch 5, matchpy 6, pytestCheckHook 7, pythonOlder 8, pytools 9}: 10 11buildPythonPackage rec { 12 pname = "pymbolic"; 13 version = "2022.2"; 14 format = "setuptools"; 15 16 disabled = pythonOlder "3.7"; 17 18 src = fetchPypi { 19 inherit pname version; 20 hash = "sha256-+Cd2lCuzy3Iyn6Hxqito7AnyN9uReMlc/ckqaup87Ik="; 21 }; 22 23 patches = [ 24 (fetchpatch { 25 url = "https://github.com/inducer/pymbolic/commit/cb3d999e4788dad3edf053387b6064adf8b08e19.patch"; 26 excludes = [ ".github/workflows/ci.yml" ]; 27 hash = "sha256-P0YjqAo0z0LZMIUTeokwMkfP8vxBXi3TcV4BSFaO1lU="; 28 }) 29 ]; 30 31 propagatedBuildInputs = [ 32 pytools 33 ]; 34 35 nativeCheckInputs = [ 36 matchpy 37 pytestCheckHook 38 ]; 39 40 postPatch = '' 41 # pytest is a test requirement not a run-time one 42 substituteInPlace setup.py \ 43 --replace '"pytest>=2.3",' "" 44 ''; 45 46 pythonImportsCheck = [ 47 "pymbolic" 48 ]; 49 50 meta = with lib; { 51 description = "A package for symbolic computation"; 52 homepage = "https://documen.tician.de/pymbolic/"; 53 license = licenses.mit; 54 maintainers = with maintainers; [ ]; 55 }; 56}