1{
2 lib,
3 aiohttp,
4 buildPythonPackage,
5 coreutils,
6 fetchFromGitHub,
7 google-auth,
8 google-auth-oauthlib,
9 google-cloud-pubsub,
10 mashumaro,
11 pytest-aiohttp,
12 pytest-asyncio,
13 pytestCheckHook,
14 pythonOlder,
15 pyyaml,
16 requests-oauthlib,
17 setuptools,
18}:
19
20buildPythonPackage rec {
21 pname = "google-nest-sdm";
22 version = "7.1.5";
23 pyproject = true;
24
25 disabled = pythonOlder "3.11";
26
27 src = fetchFromGitHub {
28 owner = "allenporter";
29 repo = "python-google-nest-sdm";
30 tag = version;
31 hash = "sha256-YpXpQnfRp5Kvr3fNAnlwsZwJdXuES7KXOykt+YK5Wz4=";
32 };
33
34 build-system = [ setuptools ];
35
36 dependencies = [
37 aiohttp
38 google-auth
39 google-auth-oauthlib
40 google-cloud-pubsub
41 mashumaro
42 pyyaml
43 requests-oauthlib
44 ];
45
46 __darwinAllowLocalNetworking = true;
47
48 nativeCheckInputs = [
49 coreutils
50 pytest-aiohttp
51 pytest-asyncio
52 pytestCheckHook
53 ];
54
55 pythonImportsCheck = [ "google_nest_sdm" ];
56
57 disabledTests = [
58 "test_clip_preview_transcode"
59 "test_event_manager_event_expiration_with_transcode"
60 ];
61
62 meta = with lib; {
63 description = "Module for Google Nest Device Access using the Smart Device Management API";
64 homepage = "https://github.com/allenporter/python-google-nest-sdm";
65 changelog = "https://github.com/allenporter/python-google-nest-sdm/releases/tag/${src.tag}";
66 license = licenses.asl20;
67 maintainers = with maintainers; [ fab ];
68 mainProgram = "google_nest";
69 };
70}