1{
2 lib,
3 buildPythonPackage,
4 fetchFromGitHub,
5 pytestCheckHook,
6 pythonOlder,
7 requests,
8 setuptools,
9}:
10
11buildPythonPackage rec {
12 pname = "sunweg";
13 version = "2.1.1";
14 pyproject = true;
15
16 disabled = pythonOlder "3.7";
17
18 src = fetchFromGitHub {
19 owner = "rokam";
20 repo = "sunweg";
21 rev = "refs/tags/${version}";
22 hash = "sha256-fgNtxCBIuNulCfuDaEsM7kL1WpwNE9O+JQ1DMZrz5jA=";
23 };
24
25 nativeBuildInputs = [ setuptools ];
26
27 propagatedBuildInputs = [ requests ];
28
29 # Module has no tests
30 doCheck = false;
31
32 pythonImportsCheck = [ "sunweg" ];
33
34 meta = with lib; {
35 description = "Module to access the WEG solar energy platform";
36 homepage = "https://github.com/rokam/sunweg";
37 changelog = "https://github.com/rokam/sunweg/releases/tag/${version}";
38 license = licenses.mit;
39 maintainers = with maintainers; [ fab ];
40 };
41}