1{
2 aiohttp,
3 buildPythonPackage,
4 fetchFromGitHub,
5 lib,
6 pytest-asyncio,
7 pytestCheckHook,
8 requests,
9 setuptools,
10 ujson,
11}:
12
13buildPythonPackage rec {
14 pname = "ayla-iot-unofficial";
15 version = "1.5.0";
16 pyproject = true;
17
18 src = fetchFromGitHub {
19 owner = "rewardone";
20 repo = "ayla-iot-unofficial";
21 tag = "v${version}";
22 hash = "sha256-/Js2XMhGe4zPAjpeH2ON4377TAPaWPvA8+HEliYKxlw=";
23 };
24
25 build-system = [ setuptools ];
26
27 dependencies = [
28 aiohttp
29 requests
30 ujson
31 ];
32
33 pythonImportsCheck = [ "ayla_iot_unofficial" ];
34
35 nativeCheckInputs = [
36 pytest-asyncio
37 pytestCheckHook
38 ];
39
40 enabledTestPaths = [ "tests/ayla_iot_unofficial.py" ];
41
42 # tests interact with the actual API
43 doCheck = false;
44
45 meta = {
46 changelog = "https://github.com/rewardone/ayla-iot-unofficial/releases/tag/${src.tag}";
47 description = "Unofficial python library for interacting with the Ayla IoT API";
48 homepage = "https://github.com/rewardone/ayla-iot-unofficial";
49 license = lib.licenses.mit;
50 maintainers = with lib.maintainers; [ dotlambda ];
51 };
52}