Merge pull request #268619 from tweag/lib-descriptions
[NixPkgs.git] / pkgs / development / python-modules / pypytools / default.nix
blobecc86e4fe2f89ed6c8a45c9c50b75134736e7239
1 { lib
2 , buildPythonPackage
3 , fetchpatch
4 , fetchPypi
5 , freezegun
6 , numpy
7 , py
8 , pytestCheckHook
9 , pythonAtLeast
10 , pythonOlder
13 buildPythonPackage rec {
14   pname = "pypytools";
15   version = "0.6.2";
16   format = "setuptools";
18   disabled = pythonOlder "3.7";
20   src = fetchPypi {
21     inherit pname version;
22     hash = "sha256-oUDAU+TRwLroNfQGYusAQKdRkHcazysqiDLfp77v5Sk=";
23   };
25   propagatedBuildInputs = [
26     py
27   ];
29   nativeCheckInputs = [
30     freezegun
31     numpy
32     py
33     pytestCheckHook
34   ];
36   patches = [
37     # Support for later Python releases, https://github.com/antocuni/pypytools/pull/2
38     (fetchpatch {
39       name = "support-later-python.patch";
40       url = "https://github.com/antocuni/pypytools/commit/c6aed496ec35a6ef7ce9e95084849eebc16bafef.patch";
41       hash = "sha256-YoYRZmgueQmxRtGaeP4zEVxuA0U7TB0PmoYHHVI7ICQ=";
42     })
43   ];
45   pythonImportsCheck = [
46     "pypytools"
47   ];
49   disabledTests = lib.optionals (pythonAtLeast "3.11") [
50     # https://github.com/antocuni/pypytools/issues/4
51     "test_clonefunc"
52   ];
54   meta = with lib; {
55     description = "Collection of tools to use PyPy-specific features";
56     homepage = "https://github.com/antocuni/pypytools";
57     license = licenses.mit;
58     maintainers = with maintainers; [ fab ];
59   };