depot/third_party/nixpkgs/pkgs/development/python-modules/aioguardian/default.nix
Default email ce641f4048 Project import generated by Copybara.
GitOrigin-RevId: bc5d68306b40b8522ffb69ba6cff91898c2fbbff
2021-12-06 17:07:01 +01:00

72 lines
1.3 KiB
Nix

{ lib
, aiohttp
, async-timeout
, asyncio-dgram
, asynctest
, buildPythonPackage
, docutils
, fetchFromGitHub
, poetry-core
, pytest-aiohttp
, pytest-asyncio
, pytestCheckHook
, voluptuous
}:
buildPythonPackage rec {
pname = "aioguardian";
version = "2021.11.0";
src = fetchFromGitHub {
owner = "bachya";
repo = pname;
rev = version;
sha256 = "sha256-jQIRACm0d0a5mQqlwxSTgLZfJFvGLWuJTb/MacppmS4=";
};
format = "pyproject";
nativeBuildInputs = [
poetry-core
];
propagatedBuildInputs = [
aiohttp
async-timeout
asyncio-dgram
docutils
voluptuous
];
checkInputs = [
asyncio-dgram
asynctest
pytest-aiohttp
pytest-asyncio
pytestCheckHook
];
postPatch = ''
substituteInPlace pyproject.toml \
--replace 'docutils = "<0.18"' 'docutils = "*"'
'';
disabledTestPaths = [
"examples/"
];
pythonImportsCheck = [
"aioguardian"
];
meta = with lib; {
description = " Python library to interact with Elexa Guardian devices";
longDescription = ''
aioguardian is a Pytho3, asyncio-focused library for interacting with the
Guardian line of water valves and sensors from Elexa.
'';
homepage = "https://github.com/bachya/aioguardian";
license = with licenses; [ mit ];
maintainers = with maintainers; [ fab ];
};
}