diff options
Diffstat (limited to 'nixpkgs/pkgs/development/python-modules/pytibber/default.nix')
-rw-r--r-- | nixpkgs/pkgs/development/python-modules/pytibber/default.nix | 51 |
1 files changed, 51 insertions, 0 deletions
diff --git a/nixpkgs/pkgs/development/python-modules/pytibber/default.nix b/nixpkgs/pkgs/development/python-modules/pytibber/default.nix new file mode 100644 index 000000000000..a8814b1e783e --- /dev/null +++ b/nixpkgs/pkgs/development/python-modules/pytibber/default.nix @@ -0,0 +1,51 @@ +{ lib +, buildPythonPackage +, pythonOlder +, fetchFromGitHub +, aiohttp +, async-timeout +, graphql-subscription-manager +, python-dateutil +, pytz +, pytestCheckHook +}: + +buildPythonPackage rec { + pname = "pytibber"; + version = "0.17.1"; + + disabled = pythonOlder "3.7"; + + src = fetchFromGitHub { + owner = "Danielhiversen"; + repo = "pyTibber"; + rev = version; + sha256 = "1zda9cvg6hy0n7sr2z71lkyl93n1gnzxrvf56lhz13pcsffshhdk"; + }; + + propagatedBuildInputs = [ + aiohttp + async-timeout + graphql-subscription-manager + python-dateutil + pytz + ]; + + checkInputs = [ + pytestCheckHook + ]; + + pytestFlagsArray = [ "test/test.py" ]; + + # tests access network + doCheck = false; + + pythonImportsCheck = [ "tibber" ]; + + meta = with lib; { + description = "A python3 library to communicate with Tibber"; + homepage = "https://github.com/Danielhiversen/pyTibber"; + license = licenses.mit; + maintainers = with maintainers; [ dotlambda ]; + }; +} |