From 0c72b4a513a642157fe426efc9d75de3f9fd50d3 Mon Sep 17 00:00:00 2001 From: Martin Weinelt Date: Wed, 4 Jan 2023 02:24:36 +0100 Subject: [PATCH] python3Packages.gipc: relax gevent constraint, enable tests --- .../python-modules/gipc/default.nix | 25 +++++++++++++++---- 1 file changed, 20 insertions(+), 5 deletions(-) diff --git a/pkgs/development/python-modules/gipc/default.nix b/pkgs/development/python-modules/gipc/default.nix index 85d17ee3ab8..84743d8606c 100644 --- a/pkgs/development/python-modules/gipc/default.nix +++ b/pkgs/development/python-modules/gipc/default.nix @@ -1,19 +1,34 @@ { lib , buildPythonPackage -, fetchPypi +, fetchFromGitHub , gevent +, pytestCheckHook }: buildPythonPackage rec { pname = "gipc"; version = "1.4.0"; + format = "setuptools"; - src = fetchPypi { - inherit pname version; - sha256 = "sha256-P8d2GIxFAAHeXjXgIxKGwahiH1TW/9fE+V0f9Ra54wo="; + src = fetchFromGitHub { + owner = "jgehrcke"; + repo = "gipc"; + rev = "refs/tags/${version}"; + hash = "sha256-T5TqLanODyzJGyjDZz+75bbz3THxoobYnfJFQxAB76E="; }; - propagatedBuildInputs = [ gevent ]; + postPatch = '' + substituteInPlace setup.py \ + --replace "gevent>=1.5,<=21.12.0" "gevent>=1.5" + ''; + + propagatedBuildInputs = [ + gevent + ]; + + checkInputs = [ + pytestCheckHook + ]; meta = with lib; { description = "gevent-cooperative child processes and IPC";