depot/third_party/nixpkgs/pkgs/development/python-modules/pytibber/default.nix
Default email 92b3d6365d Project import generated by Copybara.
GitOrigin-RevId: 412b9917cea092f3d39f9cd5dead4effd5bc4053
2022-10-30 16:09:59 +01:00

56 lines
1 KiB
Nix

{ lib
, buildPythonPackage
, pythonOlder
, fetchFromGitHub
, aiohttp
, async-timeout
, graphql-subscription-manager
, python-dateutil
, pytest-asyncio
, pytestCheckHook
}:
buildPythonPackage rec {
pname = "pytibber";
version = "0.25.6";
format = "setuptools";
disabled = pythonOlder "3.9";
src = fetchFromGitHub {
owner = "Danielhiversen";
repo = "pyTibber";
rev = "refs/tags/${version}";
hash = "sha256-aGl43gxrnKwo3ZhN+EpSBMZw0wKWf5aIPFx3goo8Nog=";
};
propagatedBuildInputs = [
aiohttp
async-timeout
graphql-subscription-manager
python-dateutil
];
checkInputs = [
pytest-asyncio
pytestCheckHook
];
pytestFlagsArray = [
"test/test.py"
];
# tests access network
doCheck = false;
pythonImportsCheck = [
"tibber"
];
meta = with lib; {
description = "Python library to communicate with Tibber";
homepage = "https://github.com/Danielhiversen/pyTibber";
license = licenses.mit;
maintainers = with maintainers; [ dotlambda ];
};
}