1{ lib 2, fetchFromGitHub 3, pythonAtLeast 4, buildPythonPackage 5, importlib-resources 6, pyyaml 7, requests 8, setuptools-scm 9, pythonOlder 10}: 11 12buildPythonPackage rec { 13 pname = "scikit-hep-testdata"; 14 version = "0.4.34"; 15 format = "pyproject"; 16 17 disabled = pythonOlder "3.6"; 18 19 src = fetchFromGitHub { 20 owner = "scikit-hep"; 21 repo = pname; 22 rev = "refs/tags/v${version}"; 23 hash = "sha256-kHpJXqFQI3vtDJIcH2ebzbaReHecwItDh73/NcoPk9A="; 24 }; 25 26 SETUPTOOLS_SCM_PRETEND_VERSION = version; 27 28 nativeBuildInputs = [ 29 setuptools-scm 30 ]; 31 32 propagatedBuildInputs = [ 33 pyyaml 34 requests 35 ] ++ lib.optionals (!pythonAtLeast "3.9") [ 36 importlib-resources 37 ]; 38 39 SKHEP_DATA = 1; # install the actual root files 40 41 doCheck = false; # tests require networking 42 43 pythonImportsCheck = [ 44 "skhep_testdata" 45 ]; 46 47 meta = with lib; { 48 homepage = "https://github.com/scikit-hep/scikit-hep-testdata"; 49 description = "A common package to provide example files (e.g., ROOT) for testing and developing packages against"; 50 changelog = "https://github.com/scikit-hep/scikit-hep-testdata/releases/tag/v${version}"; 51 license = licenses.bsd3; 52 maintainers = with maintainers; [ veprbl ]; 53 }; 54}