Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
1{ lib 2, buildPythonPackage 3, isPy27 4, fetchFromGitHub 5, flit 6, pytest 7, pytestcov 8, numpy 9, scipy 10}: 11 12buildPythonPackage rec { 13 pname = "threadpoolctl"; 14 version = "2.0.0"; 15 16 disabled = isPy27; 17 format = "flit"; 18 19 src = fetchFromGitHub { 20 owner = "joblib"; 21 repo = pname; 22 rev = version; 23 sha256 = "16z4n82f004i4l1jw6qrzazda1m6v2yjnpqlp71ipa8mzy9kw7dw"; 24 }; 25 26 checkInputs = [ pytest pytestcov numpy scipy ]; 27 28 checkPhase = "pytest tests -k 'not test_nested_prange_blas'"; 29 # cython doesn't get run on the tests when added to nativeBuildInputs, breaking this test 30 31 meta = with lib; { 32 homepage = "https://github.com/joblib/threadpoolctl"; 33 description = "Helpers to limit number of threads used in native libraries"; 34 license = licenses.bsd3; 35 maintainers = with maintainers; [ bcdarwin ]; 36 }; 37 38}