Files
nixpkgs/pkgs/development/python-modules/aiohomeconnect/default.nix
T
2025-01-04 00:19:17 +01:00

70 lines
1.3 KiB
Nix

{
lib,
authlib,
buildPythonPackage,
fastapi,
fetchFromGitHub,
httpx,
httpx-sse,
mashumaro,
poetry-core,
pytest-asyncio,
pytest-cov-stub,
pytest-httpx,
pytestCheckHook,
pythonOlder,
typer,
uvicorn,
}:
buildPythonPackage rec {
pname = "aiohomeconnect";
version = "0.7.2";
pyproject = true;
disabled = pythonOlder "3.11";
src = fetchFromGitHub {
owner = "MartinHjelmare";
repo = "aiohomeconnect";
tag = "v${version}";
hash = "sha256-E+2IQy3O+ccvZfjlORo+eTd+l41FSXk1dIE2Adrn3Ok=";
};
pythonRelaxDeps = [ "httpx" ];
build-system = [ poetry-core ];
dependencies = [
httpx
httpx-sse
mashumaro
];
optional-dependencies = {
cli = [
authlib
fastapi
typer
uvicorn
];
};
nativeCheckInputs = [
pytest-asyncio
pytest-cov-stub
pytest-httpx
pytestCheckHook
] ++ lib.flatten (builtins.attrValues optional-dependencies);
pythonImportsCheck = [ "aiohomeconnect" ];
meta = {
description = "An asyncio client for the Home Connect API";
homepage = "https://github.com/MartinHjelmare/aiohomeconnect";
changelog = "https://github.com/MartinHjelmare/aiohomeconnect/blob/${src.rev}/CHANGELOG.md";
license = lib.licenses.asl20;
maintainers = with lib.maintainers; [ fab ];
};
}