Unverified Commit ab208a6a authored by Fabian Affolter's avatar Fabian Affolter Committed by GitHub
Browse files

python312Packages.pyixapi: refactor (#341163)

parents 909cedeb 11430482
Loading
Loading
Loading
Loading
+18 −8
Original line number Diff line number Diff line
{
  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" ];

  build-system = [ poetry-core ];

  propagatedBuildInputs = [
  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;
  };