diff --git a/pkgs/development/python-modules/aiopyarr/default.nix b/pkgs/development/python-modules/aiopyarr/default.nix index 3ef60fe7185d..3d52f9d5d302 100644 --- a/pkgs/development/python-modules/aiopyarr/default.nix +++ b/pkgs/development/python-modules/aiopyarr/default.nix @@ -8,26 +8,29 @@ orjson, pytest-asyncio, pytestCheckHook, + setuptools, }: -buildPythonPackage rec { +buildPythonPackage (finalAttrs: { pname = "aiopyarr"; version = "23.4.0"; - format = "setuptools"; + pyproject = true; src = fetchFromGitHub { owner = "tkdrob"; repo = "aiopyarr"; - tag = version; + tag = finalAttrs.version; hash = "sha256-CzNB6ymvDTktiOGdcdCvWLVQ3mKmbdMpc/vezSXCpG4="; }; + build-system = [ setuptools ]; + postPatch = '' substituteInPlace setup.py \ - --replace 'version="master"' 'version="${version}"' + --replace-fail 'version="master"' 'version="${finalAttrs.version}"' ''; - propagatedBuildInputs = [ + dependencies = [ aiohttp ciso8601 orjson @@ -44,8 +47,8 @@ buildPythonPackage rec { meta = { description = "Python API client for Lidarr/Radarr/Readarr/Sonarr"; homepage = "https://github.com/tkdrob/aiopyarr"; - changelog = "https://github.com/tkdrob/aiopyarr/releases/tag/${version}"; + changelog = "https://github.com/tkdrob/aiopyarr/releases/tag/${finalAttrs.version}"; license = with lib.licenses; [ mit ]; maintainers = with lib.maintainers; [ fab ]; }; -} +})