diff --git a/pkgs/development/python-modules/vilfo-api-client/default.nix b/pkgs/development/python-modules/vilfo-api-client/default.nix index e0cda56a9349..5c4ac4ebd0f6 100644 --- a/pkgs/development/python-modules/vilfo-api-client/default.nix +++ b/pkgs/development/python-modules/vilfo-api-client/default.nix @@ -8,28 +8,32 @@ semver, pytestCheckHook, responses, + setuptools, }: -buildPythonPackage rec { +buildPythonPackage (finalAttrs: { pname = "vilfo-api-client"; version = "0.5.0"; - format = "setuptools"; + pyproject = true; src = fetchFromGitHub { owner = "ManneW"; repo = "vilfo-api-client-python"; - tag = version; + tag = finalAttrs.version; hash = "sha256-ZlmriBd+M+54ux/UNYa355mkz808/NxSz7IzmWouA0c="; }; + build-system = [ + setuptools + setuptools-scm + ]; + postPatch = '' substituteInPlace setup.cfg \ - --replace "get-mac" "getmac" + --replace-fail "get-mac" "getmac" ''; - nativeBuildInputs = [ setuptools-scm ]; - - propagatedBuildInputs = [ + dependencies = [ getmac requests semver @@ -45,7 +49,8 @@ buildPythonPackage rec { meta = { description = "Simple wrapper client for the Vilfo router API"; homepage = "https://github.com/ManneW/vilfo-api-client-python"; + changelog = "https://github.com/ManneW/vilfo-api-client-python/releases/tag/${finalAttrs.src.tag}"; license = lib.licenses.mit; maintainers = with lib.maintainers; [ dotlambda ]; }; -} +})