1{
2 lib,
3 aiohttp,
4 buildPythonPackage,
5 fetchFromGitHub,
6 pythonOlder,
7 setuptools,
8}:
9
10buildPythonPackage rec {
11 pname = "myuplink";
12 version = "0.7.0";
13 pyproject = true;
14
15 disabled = pythonOlder "3.9";
16
17 src = fetchFromGitHub {
18 owner = "pajzo";
19 repo = "myuplink";
20 tag = version;
21 hash = "sha256-r06aap8FiRslRRgKKSH7vNzpoVn6rX8ZR0oQ0D68xDo=";
22 };
23
24 postPatch = ''
25 substituteInPlace setup.cfg \
26 --replace-fail "%%VERSION_NO%%" "${version}"
27 '';
28
29 build-system = [ setuptools ];
30
31 dependencies = [ aiohttp ];
32
33 pythonImportsCheck = [ "myuplink" ];
34
35 meta = with lib; {
36 description = "Module to interact with the myUplink API";
37 homepage = "https://github.com/pajzo/myuplink";
38 changelog = "https://github.com/pajzo/myuplink/releases/tag/${version}";
39 license = licenses.mit;
40 maintainers = with maintainers; [ fab ];
41 };
42}