1{
2 lib,
3 aiohttp,
4 buildPythonPackage,
5 fetchFromGitHub,
6 poetry-core,
7 pytestCheckHook,
8 pythonOlder,
9 pythonRelaxDepsHook,
10 urllib3,
11}:
12
13buildPythonPackage rec {
14 pname = "freebox-api";
15 version = "1.1.0";
16 format = "pyproject";
17
18 disabled = pythonOlder "3.8";
19
20 src = fetchFromGitHub {
21 owner = "hacf-fr";
22 repo = pname;
23 rev = "refs/tags/v${version}";
24 hash = "sha256-3i9I2RRRxLgyfzegnqjO4g+ad1v4phx6xa8HpWP1cck=";
25 };
26
27 nativeBuildInputs = [
28 poetry-core
29 pythonRelaxDepsHook
30 ];
31
32 pythonRelaxDeps = [ "urllib3" ];
33
34 propagatedBuildInputs = [
35 aiohttp
36 urllib3
37 ];
38
39 nativeCheckInputs = [ pytestCheckHook ];
40
41 pythonImportsCheck = [ "freebox_api" ];
42
43 meta = with lib; {
44 description = "Python module to interact with the Freebox OS API";
45 mainProgram = "freebox_api";
46 homepage = "https://github.com/hacf-fr/freebox-api";
47 changelog = "https://github.com/hacf-fr/freebox-api/releases/tag/v${version}";
48 license = with licenses; [ gpl3Only ];
49 maintainers = with maintainers; [ fab ];
50 };
51}