From d0be56f8c64c79ad0659175fbfe6e8ee91e44ea6 Mon Sep 17 00:00:00 2001 From: Martin Weinelt Date: Sun, 20 Jun 2021 21:53:14 +0200 Subject: [PATCH] python3Packages.emv: relax click and pyscard constraint --- .../development/python-modules/emv/default.nix | 18 ++++++++++++------ 1 file changed, 12 insertions(+), 6 deletions(-) diff --git a/pkgs/development/python-modules/emv/default.nix b/pkgs/development/python-modules/emv/default.nix index f68729a42b62..c636af4d8cbd 100644 --- a/pkgs/development/python-modules/emv/default.nix +++ b/pkgs/development/python-modules/emv/default.nix @@ -15,7 +15,15 @@ buildPythonPackage rec { hash = "sha256:1715hcba3fdi0i5awnrjdjnk74p66sxm9349pd8bb717zrh4gpj7"; }; - checkInputs = [ pytestCheckHook ]; + postPatch = '' + # argparse is part of the standard libary since python 2.7/3.2 + sed -i '/argparse==1.4.0/d' setup.py + + substituteInPlace setup.py \ + --replace "click==7.1.2" "click" \ + --replace "pyscard==2.0.0" "pyscard" + ''; + propagatedBuildInputs = [ enum-compat click @@ -24,11 +32,9 @@ buildPythonPackage rec { terminaltables ]; - # argparse is part of the standardlib - prePatch = '' - substituteInPlace setup.py \ - --replace '"argparse==1.4.0",' "" - ''; + checkInputs = [ + pytestCheckHook + ]; meta = with lib; { homepage = "https://github.com/russss/python-emv";