depot/third_party/nixpkgs/pkgs/development/python-modules/aiorecollect/default.nix
Default email fa5436e0a7 Project import generated by Copybara.
GitOrigin-RevId: e8057b67ebf307f01bdcc8fba94d94f75039d1f6
2024-06-05 17:53:02 +02:00

66 lines
1.5 KiB
Nix

{
lib,
aiohttp,
aresponses,
buildPythonPackage,
fetchFromGitHub,
freezegun,
poetry-core,
pytest-asyncio,
pytestCheckHook,
pythonOlder,
}:
buildPythonPackage rec {
pname = "aiorecollect";
version = "2023.12.0";
format = "pyproject";
disabled = pythonOlder "3.9";
src = fetchFromGitHub {
owner = "bachya";
repo = pname;
rev = "refs/tags/${version}";
hash = "sha256-Rj0+r7eERLY5VzmuDQH/TeVLfmvmKwPqcvd1b/To0Ts=";
};
postPatch = ''
# this is not used directly by the project
sed -i '/certifi =/d' pyproject.toml
'';
nativeBuildInputs = [ poetry-core ];
propagatedBuildInputs = [ aiohttp ];
__darwinAllowLocalNetworking = true;
nativeCheckInputs = [
aresponses
freezegun
pytest-asyncio
pytestCheckHook
];
disabledTestPaths = [
# Ignore the examples directory as the files are prefixed with test_.
"examples/"
];
pythonImportsCheck = [ "aiorecollect" ];
meta = with lib; {
description = "Python library for the Recollect Waste API";
longDescription = ''
aiorecollect is a Python asyncio-based library for the ReCollect
Waste API. It allows users to programmatically retrieve schedules
for waste removal in their area, including trash, recycling, compost
and more.
'';
homepage = "https://github.com/bachya/aiorecollect";
changelog = "https://github.com/bachya/aiorecollect/releases/tag/${version}";
license = with licenses; [ mit ];
maintainers = with maintainers; [ fab ];
};
}