From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp0 ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms11 with LMTPS id eI1vK/2Ow16JZQAA0tVLHw (envelope-from ) for ; Tue, 19 May 2020 07:47:09 +0000 Received: from aspmx1.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp0 with LMTPS id QApSJ/2Ow16AIgAA1q6Kng (envelope-from ) for ; Tue, 19 May 2020 07:47:09 +0000 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id 19437940448 for ; Tue, 19 May 2020 07:47:09 +0000 (UTC) Received: from localhost ([::1]:55536 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jawxu-0004fe-Bd for larch@yhetil.org; Tue, 19 May 2020 03:47:06 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:47790) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jawxq-0004fI-Pc for guix-patches@gnu.org; Tue, 19 May 2020 03:47:02 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:37542) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1jawxq-0006rt-H1 for guix-patches@gnu.org; Tue, 19 May 2020 03:47:02 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1jawxq-0004SX-FI for guix-patches@gnu.org; Tue, 19 May 2020 03:47:02 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#41393] [PATCH] gnu: python-shouldbe: Python 3.8 compatibility Resent-From: Lars-Dominik Braun Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Tue, 19 May 2020 07:47:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 41393 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 41393@debbugs.gnu.org X-Debbugs-Original-To: guix-patches@gnu.org Received: via spool by submit@debbugs.gnu.org id=B.158987442117132 (code B ref -1); Tue, 19 May 2020 07:47:02 +0000 Received: (at submit) by debbugs.gnu.org; 19 May 2020 07:47:01 +0000 Received: from localhost ([127.0.0.1]:49088 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1jawxo-0004SG-Pd for submit@debbugs.gnu.org; Tue, 19 May 2020 03:47:01 -0400 Received: from lists.gnu.org ([209.51.188.17]:54608) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1jawxl-0004S7-T0 for submit@debbugs.gnu.org; Tue, 19 May 2020 03:47:00 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:47786) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jawxl-0004f2-It for guix-patches@gnu.org; Tue, 19 May 2020 03:46:57 -0400 Received: from mail-wm1-x341.google.com ([2a00:1450:4864:20::341]:37437) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1jawxh-0006qO-B4 for guix-patches@gnu.org; Tue, 19 May 2020 03:46:57 -0400 Received: by mail-wm1-x341.google.com with SMTP id z72so2280283wmc.2 for ; Tue, 19 May 2020 00:46:52 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=leibniz-psychology-org.20150623.gappssmtp.com; s=20150623; h=date:from:to:subject:message-id:mime-version:content-disposition :user-agent; bh=zgh8vkVjhJKJhC2O1q+/6ckfpGh3hLgOcofES5FKf08=; b=Z3x8IbWwgfH/Cvq/cb1P4pzSSDCuOV6wMQtfr03/LYRZ6woUqkmxq7m4PAsDKeVRK/ GiJ2Gonl3zt5+XP72ITRjixLmypHkqzby72okJ9fmZq4fXPZtfoax/Iwzy8XNI1QHSl1 iJ9ziS+X322VDjTU8KwpBfijJIHfd8/gb75Y+qxBsgs3UjD/VKYACeTqNkDoNtJG/CHP wALdkjUJjkT3xnNhyXVD8+HS24qInyrBcqlbDKS+G08obNflbFgSrzJxB7FuA2+kAWOp VQY2FqlPgDJYlTIc/yKbL0qvsxrKN9JI+dN9Fpr8ioXCqNLTKokkVZKNEWioaEX8Gn5R kwLQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:subject:message-id:mime-version :content-disposition:user-agent; bh=zgh8vkVjhJKJhC2O1q+/6ckfpGh3hLgOcofES5FKf08=; b=K9O3cO6DVqohHuH97Bnk/N1LRTqU7pobNMFCAb0QSgHcZBBAk6wnaoSS4Vdg3bxV3h wm3RLBlorhg0L6CQPaVBTXm+rePvW65f633ClcBCNQlilntyiLzwQzBKo9RNnudi4nJq ncd1buCYIIerAE9N1+yEdsg5CoDT3mtG+V6GjBEJzGpo2mggOR31mfZgvR4H5khmvZwd bZTNihsUl2sAUtimmFtWQnEsq1kkvAwHJeKgRqhrmE3KH1g2tOZmJJbq5JrGSym5CZ48 h1qMHVgqUXCa05UpGhOJB4bl8qz82uDUFNoSsbnRwajdK9wtsZfzEOOltFuKK5b2GvBC /7PA== X-Gm-Message-State: AOAM530oRDnEd2aWibvrxtEATVmfmk7ZUAsak32/UCN58hs6H3x//cTd P1q5IgvUNOAEgmyawiuPQSQdCQ2DBhV9UXg4WF9zI5uGGACF8e2XNaO09NxpR9LJb9xfBOSF4MV k451n63G9xlTU52yLBxBdkWN6AtDWI4vOj3fJ6OPdappr2a2QR8MRkIlgusDsUoO26ysLuxfGZE rZCbwy0HE= X-Google-Smtp-Source: ABdhPJzUgHQnA5o0sMpJzGrbIHmTgDX+JbzEu1DVn91apwqVqYxSJq1gnesz510TAd5sFqZPv4J0SA== X-Received: by 2002:a1c:2087:: with SMTP id g129mr3740959wmg.126.1589874410940; Tue, 19 May 2020 00:46:50 -0700 (PDT) Received: from localhost (dynamic-2a01-0c23-7850-5200-7d0a-d634-6a10-7df9.c23.pool.telefonica.de. [2a01:c23:7850:5200:7d0a:d634:6a10:7df9]) by smtp.gmail.com with ESMTPSA id f8sm18877700wrm.8.2020.05.19.00.46.50 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 19 May 2020 00:46:50 -0700 (PDT) Date: Tue, 19 May 2020 09:46:49 +0200 From: Lars-Dominik Braun Message-ID: <20200519074649.GA11910@zpidnp36> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="ZGiS0Q5IWpPtfppv" Content-Disposition: inline User-Agent: Mutt/1.10.1 (2018-07-13) Received-SPF: none client-ip=2a00:1450:4864:20::341; envelope-from=ldb@leibniz-psychology.org; helo=mail-wm1-x341.google.com X-detected-operating-system: by eggs.gnu.org: No matching host in p0f cache. That's all we know. X-Spam_score_int: -18 X-Spam_score: -1.9 X-Spam_bar: - X-Spam_report: (-1.9 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, URIBL_BLOCKED=0.001 autolearn=_AUTOLEARN X-Spam_action: no action X-Spam-Score: -2.3 (--) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-Spam-Score: -3.3 (---) X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+larch=yhetil.org@gnu.org Sender: "Guix-patches" X-Scanner: scn0 Authentication-Results: aspmx1.migadu.com; dkim=fail (rsa verify failed) header.d=leibniz-psychology-org.20150623.gappssmtp.com header.s=20150623 header.b=Z3x8IbWw; dmarc=none; spf=pass (aspmx1.migadu.com: domain of guix-patches-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=guix-patches-bounces@gnu.org X-Spam-Score: -1.61 X-TUID: Llgbx8ckFDwj --ZGiS0Q5IWpPtfppv Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Upstream issue: https://github.com/DirectXMan12/should_be/pull/5 * gnu/packages/patches/python-shouldbe-0.1.2-cpy3.8.patch: Add compatibilit= y patch * gnu/local.mk (dist_patch_DATA): Add new file * gnu/packages/python-xyz.scm (python-shouldbe)[source]: Add patch --- gnu/local.mk | 1 + .../python-shouldbe-0.1.2-cpy3.8.patch | 78 +++++++++++++++++++ gnu/packages/python-xyz.scm | 3 +- 3 files changed, 81 insertions(+), 1 deletion(-) create mode 100644 gnu/packages/patches/python-shouldbe-0.1.2-cpy3.8.patch diff --git a/gnu/local.mk b/gnu/local.mk index 38b286203e..7ab5882f1b 100644 --- a/gnu/local.mk +++ b/gnu/local.mk @@ -1432,6 +1432,7 @@ dist_patch_DATA =3D \ %D%/packages/patches/python2-pygobject-2-gi-info-type-error-domain.patch= \ %D%/packages/patches/python-pygpgme-fix-pinentry-tests.patch \ %D%/packages/patches/python-robotframework-honor-source-date-epoch.patch= \ + %D%/packages/patches/python-shouldbe-0.1.2-cpy3.8.patch \ %D%/packages/patches/python-slugify-depend-on-unidecode.patch \ %D%/packages/patches/python2-subprocess32-disable-input-test.patch \ %D%/packages/patches/python-unittest2-python3-compat.patch \ diff --git a/gnu/packages/patches/python-shouldbe-0.1.2-cpy3.8.patch b/gnu/= packages/patches/python-shouldbe-0.1.2-cpy3.8.patch new file mode 100644 index 0000000000..0a80d15cd2 --- /dev/null +++ b/gnu/packages/patches/python-shouldbe-0.1.2-cpy3.8.patch @@ -0,0 +1,78 @@ +diff -x '*.pyc' -Naur shouldbe-0.1.2/should_be/core.py shouldbe-0.1.2.patc= hed/should_be/core.py +--- shouldbe-0.1.2/should_be/core.py 2019-03-06 07:38:22.000000000 +0100 ++++ shouldbe-0.1.2.patched/should_be/core.py 2020-05-18 08:44:24.214664704= +0200 +@@ -103,7 +103,7 @@ + return resf +=20 +=20 +-def buildCode(baseCode, argcount=3DNone, kwonlyargcount=3DNone, ++def buildCode(baseCode, argcount=3DNone, posonlyargcount=3DNone, kwonlyar= gcount=3DNone, + nlocals=3DNone, stacksize=3DNone, flags=3DNone, + code=3DNone, consts=3DNone, names=3DNone, + varnames=3DNone, filename=3DNone, name=3DNone, +@@ -121,6 +121,24 @@ + nlocals or baseCode.co_nlocals, + stacksize or baseCode.co_stacksize, + flags or baseCode.co_flags, ++ code or baseCode.co_code, ++ consts or baseCode.co_consts, ++ names or baseCode.co_names, ++ varnames or baseCode.co_varnames, ++ filename or baseCode.co_filename, ++ name or baseCode.co_name, ++ firstlineno or baseCode.co_firstlineno, ++ lnotab or baseCode.co_lnotab, ++ freevars or baseCode.co_freevars, ++ cellvars or baseCode.co_cellvars) ++ elif hasattr(baseCode, 'co_posonlyargcount'): ++ # Python 3.8 ++ resc =3D CodeType(argcount or baseCode.co_argcount, ++ posonlyargcount or baseCode.co_posonlyargcount, ++ kwonlyargcount or baseCode.co_kwonlyargcount, ++ nlocals or baseCode.co_nlocals, ++ stacksize or baseCode.co_stacksize, ++ flags or baseCode.co_flags, + code or baseCode.co_code, + consts or baseCode.co_consts, + names or baseCode.co_names, +diff -x '*.pyc' -Naur shouldbe-0.1.2/should_be/tests/test_container_mixin.= py shouldbe-0.1.2.patched/should_be/tests/test_container_mixin.py +--- shouldbe-0.1.2/should_be/tests/test_container_mixin.py 2019-03-01 06:3= 8:16.000000000 +0100 ++++ shouldbe-0.1.2.patched/should_be/tests/test_container_mixin.py 2020-05= -18 09:00:51.372531064 +0200 +@@ -7,31 +7,31 @@ + self.lst =3D [1, 2, 3] +=20 + def test_should_include_iter(self): +- err_msg =3D (r'[a-zA-Z0-9.]+ should have included \[.+?\]' ++ err_msg =3D (r'[a-zA-Z0-9.()]+ should have included \[.+?\]' + r', but did not have items .+') +- self.assertRaisesRegexp(AssertionError, err_msg, ++ self.assertRaisesRegex(AssertionError, err_msg, + self.lst.should_include, [4]) +=20 + self.lst.should_include([1, 2, 3]) +=20 + def test_should_include_item(self): +- err_msg =3D (r'[a-zA-Z0-9.]+ should have included .+?' ++ err_msg =3D (r'[a-zA-Z0-9.()]+ should have included .+?' + r', but did not') +- self.assertRaisesRegexp(AssertionError, err_msg, ++ self.assertRaisesRegex(AssertionError, err_msg, + self.lst.should_include, 4) +=20 + self.lst.should_include(3) +=20 + def test_shouldnt_include_iter(self): + err_msg =3D 'should not have included' +- self.assertRaisesRegexp(AssertionError, err_msg, ++ self.assertRaisesRegex(AssertionError, err_msg, + self.lst.shouldnt_include, [2, 3]) +=20 + self.lst.shouldnt_include([4, 5]) +=20 + def test_shouldnt_include_item(self): + err_msg =3D 'should not have included' +- self.assertRaisesRegexp(AssertionError, err_msg, ++ self.assertRaisesRegex(AssertionError, err_msg, + self.lst.shouldnt_include, 3) +=20 + self.lst.shouldnt_include(4) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index c26a766d64..00a4fd51c4 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -18749,7 +18749,8 @@ and cuts down boilerplate code when testing librari= es for asyncio.") (uri (pypi-uri "shouldbe" version)) (sha256 (base32 - "16zbvjxf71dl4yfbgcr6idyim3mdrfvix1dv8b95p0s9z07372pj")))) + "16zbvjxf71dl4yfbgcr6idyim3mdrfvix1dv8b95p0s9z07372pj")) + (patches (search-patches "python-shouldbe-0.1.2-cpy3.8.patch")))) (build-system python-build-system) (propagated-inputs `(("python-forbiddenfruit" ,python-forbiddenfruit))) --=20 2.20.1 --ZGiS0Q5IWpPtfppv Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQGzBAABCgAdFiEEyk+M9DfXR4/aBV/UQhN3ARo3hEYFAl7DjuYACgkQQhN3ARo3 hEYLWgv+K0VSFV/vwFsvLSZ/33Dn9QEb0iXVKVunIFRgpFKCBLKoLZGGhfeHpsK2 Jcj6nf4zDoSBppzdqGhxOCNc97uBem6YZCeyTdtlzpqJ3mxJX/x0so4O91fX9dN8 OBhh9Gn8R7do+7yvitUkQs0vtOydEPVfonXN9IJ4oK2EWI7gooWT4Jnluh/Orf+H IslJ5tjWBJfwazZGN45P39Ox3GfvcNt91J/+Ux16Ead/7GgCeDqUWT5TDMN6nS85 rL/QNgMFy7G07gyYASwTyjTFS8Id2JhqdOu00xUpwdpcj3cvEGVMXpUEafTbaaZn yvxZCjQcH9w6wJWv4xytWA7jx/pXGT5Gh5hXQ3nGttoFS57wR+R7YGAVkOhOKZQY 72Zax8aVSnNcjLwiCmcz0wBqsreqGvXYeGNhR5bLbMFmLe1Gq3Xh8KF4jQ0PPp+j rP8EiiwgkkQRieXmsQ4O38f33kV8CrKbIwpOlF1grzAC7CM783vnsANBX2s077gv 3GTtX7m7 =xmTm -----END PGP SIGNATURE----- --ZGiS0Q5IWpPtfppv--