[arch-commits] Commit in python-sure/trunk (PKGBUILD python310.diff)
Chih-Hsuan Yen
yan12125 at gemini.archlinux.org
Tue Dec 7 12:44:45 UTC 2021
Date: Tuesday, December 7, 2021 @ 12:44:44
Author: yan12125
Revision: 1065520
python-sure: fix for Python 3.10
See: https://github.com/gabrielfalcao/sure/issues/169
Added:
python-sure/trunk/python310.diff
Modified:
python-sure/trunk/PKGBUILD
----------------+
PKGBUILD | 12 +++++++++---
python310.diff | 13 +++++++++++++
2 files changed, 22 insertions(+), 3 deletions(-)
Modified: PKGBUILD
===================================================================
--- PKGBUILD 2021-12-07 11:55:06 UTC (rev 1065519)
+++ PKGBUILD 2021-12-07 12:44:44 UTC (rev 1065520)
@@ -2,7 +2,7 @@
pkgname=python-sure
pkgver=2.0.0
-pkgrel=2
+pkgrel=3
pkgdesc="An idiomatic testing library for python with powerful and flexible assertions"
arch=('any')
url="https://github.com/gabrielfalcao/sure"
@@ -10,11 +10,17 @@
depends=('python-six' 'python-mock')
makedepends=('python-setuptools' 'git')
checkdepends=('python-nose' 'python-rednose')
-source=("$pkgname-$pkgver.tar.gz::https://github.com/gabrielfalcao/sure/archive/$pkgver.tar.gz")
-sha512sums=('d113b08afd63c379ec9f05169b1ad15f3bb616a1f6ad7d0ef6513e98ba7ebb7462254b2d25307906d9f63603fed4f9e4b83ccbca0ec53a2b483f9395fa0fb94a')
+source=("$pkgname-$pkgver.tar.gz::https://github.com/gabrielfalcao/sure/archive/$pkgver.tar.gz"
+ "python310.diff")
+sha512sums=('d113b08afd63c379ec9f05169b1ad15f3bb616a1f6ad7d0ef6513e98ba7ebb7462254b2d25307906d9f63603fed4f9e4b83ccbca0ec53a2b483f9395fa0fb94a'
+ '0703cc88d01928e25e94e92fc0cfee68c6759322c9ee1d1603f381b6d67d6cf9db97f26aad1ccf7f6d6702370bc2c0194245aa3ba1c1b1384027a5712e469139')
prepare() {
export LC_CTYPE=en_US.UTF-8
+
+ cd "$srcdir"/sure-$pkgver
+ # https://github.com/gabrielfalcao/sure/issues/169
+ patch -Np1 -i ../python310.diff
}
build() {
Added: python310.diff
===================================================================
--- python310.diff (rev 0)
+++ python310.diff 2021-12-07 12:44:44 UTC (rev 1065520)
@@ -0,0 +1,13 @@
+diff --git a/sure/__init__.py b/sure/__init__.py
+index ef50bd4..d4c2afb 100644
+--- a/sure/__init__.py
++++ b/sure/__init__.py
+@@ -126,7 +126,7 @@ class CallBack(object):
+ err = traceback.format_exc().splitlines()[-1]
+ err = err.replace("{0}:".format(exc_klass.__name__), "").strip()
+
+- if err.startswith(self.callback_name) and (
++ if self.callback_name in err and (
+ "takes no arguments (1 given)" in err
+ or "takes 0 positional arguments but 1 was given" in err
+ ):
More information about the arch-commits
mailing list