nixpkgs mirror (for testing)
github.com/NixOS/nixpkgs
nix
1{ lib
2, buildPythonPackage
3, pythonOlder
4, fetchFromGitHub
5, aiohttp
6, async-timeout
7, graphql-subscription-manager
8, python-dateutil
9, pytz
10, pytest-asyncio
11, pytestCheckHook
12}:
13
14buildPythonPackage rec {
15 pname = "pytibber";
16 version = "0.22.3";
17 format = "setuptools";
18
19 disabled = pythonOlder "3.9";
20
21 src = fetchFromGitHub {
22 owner = "Danielhiversen";
23 repo = "pyTibber";
24 rev = version;
25 hash = "sha256-tM8Uu/TpP5a7y+ePFko0bMoZJWG2efYA861Ez8dPeFY=";
26 };
27
28 propagatedBuildInputs = [
29 aiohttp
30 async-timeout
31 graphql-subscription-manager
32 python-dateutil
33 pytz
34 ];
35
36 checkInputs = [
37 pytest-asyncio
38 pytestCheckHook
39 ];
40
41 pytestFlagsArray = [
42 "test/test.py"
43 ];
44
45 # tests access network
46 doCheck = false;
47
48 pythonImportsCheck = [
49 "tibber"
50 ];
51
52 meta = with lib; {
53 description = "Python library to communicate with Tibber";
54 homepage = "https://github.com/Danielhiversen/pyTibber";
55 license = licenses.mit;
56 maintainers = with maintainers; [ dotlambda ];
57 };
58}