1{
2 lib,
3 aiohttp,
4 bitstruct,
5 buildPythonPackage,
6 cryptography,
7 fetchFromGitHub,
8 pytest-asyncio,
9 pytestCheckHook,
10 pythonOlder,
11 setuptools,
12 voluptuous,
13}:
14
15buildPythonPackage rec {
16 pname = "python-otbr-api";
17 version = "2.6.0";
18 pyproject = true;
19
20 disabled = pythonOlder "3.9";
21
22 src = fetchFromGitHub {
23 owner = "home-assistant-libs";
24 repo = "python-otbr-api";
25 rev = "refs/tags/${version}";
26 hash = "sha256-RMj4NdEbMIxh2PDzbhUWgmcdzRXY8RxcQNN/bbGOW5Q=";
27 };
28
29 nativeBuildInputs = [ setuptools ];
30
31 propagatedBuildInputs = [
32 aiohttp
33 bitstruct
34 cryptography
35 voluptuous
36 ];
37
38 nativeCheckInputs = [
39 pytest-asyncio
40 pytestCheckHook
41 ];
42
43 pythonImportsCheck = [ "python_otbr_api" ];
44
45 meta = with lib; {
46 description = "Library for the Open Thread Border Router";
47 homepage = "https://github.com/home-assistant-libs/python-otbr-api";
48 changelog = "https://github.com/home-assistant-libs/python-otbr-api/releases/tag/${version}";
49 license = licenses.mit;
50 maintainers = with maintainers; [ fab ];
51 };
52}