Merge pull request #307098 from r-ryantm/auto-update/cilium-cli
[NixPkgs.git] / pkgs / development / python-modules / pytest-openfiles / default.nix
blobda894eff91e355c0a756fe17c60429b20d192b01
1 { lib
2 , buildPythonPackage
3 , fetchpatch
4 , fetchPypi
5 , isPy27
6 , packaging
7 , pytest
8 , pytestCheckHook
9 , psutil
10 , setuptools-scm
13 buildPythonPackage rec {
14   pname = "pytest-openfiles";
15   version = "0.5.0";
16   format = "setuptools";
17   disabled = isPy27; # abandoned
19   src = fetchPypi {
20     inherit pname version;
21     sha256 = "179c2911d8aee3441fee051aba08e0d9b4dab61b829ae4811906d5c49a3b0a58";
22   };
24   patches = [
25     (fetchpatch {
26       name = "replace-distutils-with-packaging.patch";
27       url = "https://github.com/astropy/pytest-openfiles/commit/e17e8123936689b0b0ecfb713976588d6793d8bb.patch";
28       includes = [ "pytest_openfiles/plugin.py" ];
29       hash = "sha256-+6xqOwnBO+jxenXxPdDhLqqm3w+ZRjWeVqqgz8j22bU=";
30     })
31   ];
33   nativeBuildInputs = [ setuptools-scm ];
35   buildInputs = [ pytest ];
37   propagatedBuildInputs = [
38     packaging
39     psutil
40   ];
42   nativeCheckInputs = [ pytestCheckHook ];
44   meta = with lib; {
45     description = "Pytest plugin for detecting inadvertent open file handles";
46     homepage = "https://astropy.org";
47     license = licenses.bsd3;
48     maintainers = [ ];
49   };