Merge pull request #307098 from r-ryantm/auto-update/cilium-cli
[NixPkgs.git] / pkgs / development / python-modules / pyeapi / default.nix
bloba7063c55e7aeb784e59ceeaa3f0f58e1ca4fbb30
2   lib,
3   buildPythonPackage,
4   fetchFromGitHub,
5   fetchpatch,
6   setuptools,
7   mock,
8   netaddr,
9   pytestCheckHook,
10   pythonOlder,
13 buildPythonPackage rec {
14   pname = "pyeapi";
15   version = "1.0.2";
16   pyproject = true;
18   disabled = pythonOlder "3.7";
20   src = fetchFromGitHub {
21     owner = "arista-eosplus";
22     repo = "pyeapi";
23     rev = "refs/tags/v${version}";
24     hash = "sha256-GZBoCoAqij54rZezRDF/ihJDQ5T6FFyDSRXGV3//avQ=";
25   };
27   patches = [
28     # Replace imp, https://github.com/arista-eosplus/pyeapi/pull/295
29     (fetchpatch {
30       name = "replace-imp.patch";
31       url = "https://github.com/arista-eosplus/pyeapi/commit/1f2d8e1fa61566082ccb11a1a17e0f3d8a0c89df.patch";
32       hash = "sha256-ONviRU6eUUZ+TTJ4F41ZXqavW7RIi1MBO7s7OsnWknk=";
33     })
34   ];
36   build-system = [ setuptools ];
38   dependencies = [ netaddr ];
40   nativeCheckInputs = [
41     mock
42     pytestCheckHook
43   ];
45   pytestFlagsArray = [ "test/unit" ];
47   pythonImportsCheck = [ "pyeapi" ];
49   meta = with lib; {
50     description = "Client for Arista eAPI";
51     homepage = "https://github.com/arista-eosplus/pyeapi";
52     changelog = "https://github.com/arista-eosplus/pyeapi/releases/tag/v${version}";
53     license = licenses.bsd3;
54     maintainers = with maintainers; [ astro ];
55   };