diff --git a/pkgs/development/python-modules/pyixapi/default.nix b/pkgs/development/python-modules/pyixapi/default.nix index 3a051450c5dc..50c825dcc959 100644 --- a/pkgs/development/python-modules/pyixapi/default.nix +++ b/pkgs/development/python-modules/pyixapi/default.nix @@ -1,10 +1,12 @@ { lib, buildPythonPackage, - fetchPypi, + fetchFromGitHub, poetry-core, - requests, pyjwt, + pythonOlder, + pytestCheckHook, + requests, }: buildPythonPackage rec { @@ -12,24 +14,32 @@ buildPythonPackage rec { version = "0.2.3"; pyproject = true; - src = fetchPypi { - inherit pname version; - hash = "sha256-qkgPBIYv9xzGa29RiPAU3zNhcyutTUX1Vkmpd9YdeJU="; + disabled = pythonOlder "3.8"; + + src = fetchFromGitHub { + owner = "peering-manager"; + repo = "pyixapi"; + rev = "refs/tags/${version}"; + hash = "sha256-IiLjxOtyxGSaItxgEbsF8AER/j4Qe7SP9ZAEPjTiYI4="; }; - nativeBuildInputs = [ poetry-core ]; + pythonRelaxDeps = [ "pyjwt" ]; - propagatedBuildInputs = [ + build-system = [ poetry-core ]; + + dependencies = [ requests pyjwt ]; + nativeCheckInputs = [ pytestCheckHook ]; + pythonImportsCheck = [ "pyixapi" ]; meta = with lib; { + description = "Python API client library for IX-API"; homepage = "https://github.com/peering-manager/pyixapi/"; changelog = "https://github.com/peering-manager/pyixapi/releases/tag/${version}"; - description = "Python API client library for IX-API"; license = licenses.asl20; maintainers = teams.wdz.members; };