2022-02-14 16:42:12 +00:00
|
|
|
{
|
|
|
|
lib,
|
|
|
|
aiohttp,
|
|
|
|
aresponses,
|
|
|
|
buildPythonPackage,
|
2022-10-29 08:37:37 +00:00
|
|
|
ciso8601,
|
2022-02-14 16:42:12 +00:00
|
|
|
fetchFromGitHub,
|
2022-10-29 08:37:37 +00:00
|
|
|
orjson,
|
2022-02-14 16:42:12 +00:00
|
|
|
pytest-asyncio,
|
|
|
|
pytestCheckHook,
|
|
|
|
pythonOlder,
|
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "aiopyarr";
|
2023-04-09 08:08:01 +00:00
|
|
|
version = "23.4.0";
|
2022-02-14 16:42:12 +00:00
|
|
|
format = "setuptools";
|
|
|
|
|
|
|
|
disabled = pythonOlder "3.9";
|
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "tkdrob";
|
|
|
|
repo = pname;
|
2023-04-09 08:12:34 +00:00
|
|
|
rev = "refs/tags/${version}";
|
2023-04-09 08:08:01 +00:00
|
|
|
hash = "sha256-CzNB6ymvDTktiOGdcdCvWLVQ3mKmbdMpc/vezSXCpG4=";
|
2022-02-14 16:42:12 +00:00
|
|
|
};
|
|
|
|
|
2023-03-01 17:56:24 +00:00
|
|
|
postPatch = ''
|
|
|
|
substituteInPlace setup.py \
|
|
|
|
--replace 'version="master"' 'version="${version}"'
|
|
|
|
'';
|
|
|
|
|
2022-02-14 16:42:12 +00:00
|
|
|
propagatedBuildInputs = [
|
|
|
|
aiohttp
|
2022-10-29 08:37:37 +00:00
|
|
|
ciso8601
|
|
|
|
orjson
|
2022-02-14 16:42:12 +00:00
|
|
|
];
|
|
|
|
|
2023-01-21 12:00:00 +00:00
|
|
|
nativeCheckInputs = [
|
2022-02-14 16:42:12 +00:00
|
|
|
aresponses
|
|
|
|
pytest-asyncio
|
|
|
|
pytestCheckHook
|
|
|
|
];
|
|
|
|
|
|
|
|
pythonImportsCheck = [ "aiopyarr" ];
|
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "Python API client for Lidarr/Radarr/Readarr/Sonarr";
|
|
|
|
homepage = "https://github.com/tkdrob/aiopyarr";
|
2023-04-09 08:12:34 +00:00
|
|
|
changelog = "https://github.com/tkdrob/aiopyarr/releases/tag/${version}";
|
2022-02-14 16:42:12 +00:00
|
|
|
license = with licenses; [ mit ];
|
|
|
|
maintainers = with maintainers; [ fab ];
|
|
|
|
};
|
|
|
|
}
|