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

54 lines
1.1 KiB
Nix

{
lib,
aiohttp,
aresponses,
buildPythonPackage,
ciso8601,
fetchFromGitHub,
orjson,
pytest-asyncio,
pytestCheckHook,
pythonOlder,
}:
buildPythonPackage rec {
pname = "aiopyarr";
version = "23.4.0";
format = "setuptools";
disabled = pythonOlder "3.9";
src = fetchFromGitHub {
owner = "tkdrob";
repo = pname;
rev = "refs/tags/${version}";
hash = "sha256-CzNB6ymvDTktiOGdcdCvWLVQ3mKmbdMpc/vezSXCpG4=";
};
postPatch = ''
substituteInPlace setup.py \
--replace 'version="master"' 'version="${version}"'
'';
propagatedBuildInputs = [
aiohttp
ciso8601
orjson
];
nativeCheckInputs = [
aresponses
pytest-asyncio
pytestCheckHook
];
pythonImportsCheck = [ "aiopyarr" ];
meta = with lib; {
description = "Python API client for Lidarr/Radarr/Readarr/Sonarr";
homepage = "https://github.com/tkdrob/aiopyarr";
changelog = "https://github.com/tkdrob/aiopyarr/releases/tag/${version}";
license = with licenses; [ mit ];
maintainers = with maintainers; [ fab ];
};
}