1{
2 lib,
3 buildPythonPackage,
4 fetchFromGitHub,
5 requests,
6}:
7
8buildPythonPackage rec {
9 pname = "pynut2";
10 version = "2.1.2";
11 format = "setuptools";
12
13 src = fetchFromGitHub {
14 owner = "mezz64";
15 repo = "python-nut2";
16 rev = version;
17 sha256 = "1lg7n1frndfgw73s0ssl1h7kc6zxm7fpiwlc6v6d60kxzaj1dphx";
18 };
19
20 propagatedBuildInputs = [ requests ];
21
22 pythonImportsCheck = [ "pynut2.nut2" ];
23
24 # tests are unmaintained and broken
25 doCheck = false;
26
27 meta = with lib; {
28 description = "API overhaul of PyNUT, a Python library to allow communication with NUT (Network UPS Tools) servers";
29 homepage = "https://github.com/mezz64/python-nut2";
30 license = with licenses; [ gpl3Plus ];
31 maintainers = [ maintainers.luker ];
32 };
33}