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