Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
at litex 1.3 kB view raw
1{ lib 2, attrs 3, buildPythonPackage 4, fetchFromGitHub 5, fetchPypi 6, hatch-vcs 7, hatchling 8, hepunits 9, pandas 10, pytestCheckHook 11, pythonOlder 12, setuptools-scm 13, tabulate 14}: 15 16buildPythonPackage rec { 17 pname = "particle"; 18 version = "0.21.2"; 19 format = "pyproject"; 20 21 disabled = pythonOlder "3.9"; 22 23 src = fetchPypi { 24 inherit pname version; 25 hash = "sha256-BDTTmqtPxyvORSoR+CJzb5WTfF9BFrDoMSVOvO9s/Ns="; 26 }; 27 28 postPatch = '' 29 # Disable benchmark tests, so we won't need pytest-benchmark and pytest-cov 30 # as dependencies 31 substituteInPlace pyproject.toml \ 32 --replace '"--benchmark-disable",' "" 33 ''; 34 35 nativeBuildInputs = [ 36 hatch-vcs 37 hatchling 38 ]; 39 40 propagatedBuildInputs = [ 41 attrs 42 hepunits 43 ]; 44 45 nativeCheckInputs = [ 46 pytestCheckHook 47 tabulate 48 pandas 49 ]; 50 51 pythonImportsCheck = [ 52 "particle" 53 ]; 54 55 disabledTestPaths = [ 56 "tests/particle/test_performance.py" 57 ]; 58 59 meta = with lib; { 60 description = "Package to deal with particles, the PDG particle data table and others"; 61 homepage = "https://github.com/scikit-hep/particle"; 62 changelog = "https://github.com/scikit-hep/particle/releases/tag/v${version}"; 63 license = licenses.bsd3; 64 maintainers = with maintainers; [ doronbehar ]; 65 }; 66}