* [gentoo-commits] repo/gentoo:master commit in: dev-python/chai/files/, dev-python/chai/
@ 2020-04-10 14:30 Andreas Sturmlechner
0 siblings, 0 replies; only message in thread
From: Andreas Sturmlechner @ 2020-04-10 14:30 UTC (permalink / raw
To: gentoo-commits
commit: 34b3362ad01dee92d63c1310b7875ae50413180e
Author: Chris Mayo <aklhfex <AT> gmail <DOT> com>
AuthorDate: Tue Mar 24 20:02:31 2020 +0000
Commit: Andreas Sturmlechner <asturm <AT> gentoo <DOT> org>
CommitDate: Fri Apr 10 14:19:50 2020 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=34b3362a
dev-python/chai: Bump to 1.1.2, py3.8
Avoid pyc and SyntaxErrors during install by not installing python2.py.
Package-Manager: Portage-2.3.89, Repoman-2.3.20
Signed-off-by: Chris Mayo <aklhfex <AT> gmail.com>
Closes: https://github.com/gentoo/gentoo/pull/15094
Signed-off-by: Andreas Sturmlechner <asturm <AT> gentoo.org>
dev-python/chai/Manifest | 1 +
dev-python/chai/chai-1.1.2.ebuild | 19 ++++++++++++++
.../chai/files/chai-1.1.2-drop-Python2.patch | 30 ++++++++++++++++++++++
3 files changed, 50 insertions(+)
diff --git a/dev-python/chai/Manifest b/dev-python/chai/Manifest
index 205e3089f35..bfbf42d8a84 100644
--- a/dev-python/chai/Manifest
+++ b/dev-python/chai/Manifest
@@ -1 +1,2 @@
DIST chai-1.1.1.tar.gz 81684 BLAKE2B 0aa285d3545e445f26f0b088c1b721f2dd14094a8f499cf7b2dde378a20ee15e376e43a91a664be9d6bd11b45d9c2f4606ce5de73743c27b6bb76e9bea409194 SHA512 f51406258327d9a49e820f0489d60e87f576c72232c701e99f96945932ed300582e6dd81608e5b262e2645c4e9c5216ec8f52e98d454c994beac8d1d8137dc87
+DIST chai-1.1.2.tar.gz 107807 BLAKE2B 6cedd108f7275c3dd03167c7ad49695d95c27e1b0c752247e170996f001c7690cede7c7ac8de8e374077ea9802534b8386b0bd2da7197f0a47085ad9f9e470fc SHA512 81191b11a8c5c6bd1fbb0c43fe7855d6e6d9be54b4d0ddc42582a23b9df03249a91ba8ca50b5b74e76aab73a101377624e041b6c47ea6cba5267d4b58eaf77e5
diff --git a/dev-python/chai/chai-1.1.2.ebuild b/dev-python/chai/chai-1.1.2.ebuild
new file mode 100644
index 00000000000..f031b5fb0dd
--- /dev/null
+++ b/dev-python/chai/chai-1.1.2.ebuild
@@ -0,0 +1,19 @@
+# Copyright 1999-2020 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+PYTHON_COMPAT=( python3_{6,7,8} )
+inherit distutils-r1
+
+DESCRIPTION="Easy to use mocking, stubbing and spying framework"
+HOMEPAGE="https://github.com/agoragames/chai"
+SRC_URI="mirror://pypi/${PN:0:1}/${PN}/${P}.tar.gz"
+
+LICENSE="BSD"
+SLOT="0"
+KEYWORDS="~amd64 ~arm64 ~x86"
+
+PATCHES=( "${FILESDIR}"/${P}-drop-Python2.patch )
+
+distutils_enable_tests nose
diff --git a/dev-python/chai/files/chai-1.1.2-drop-Python2.patch b/dev-python/chai/files/chai-1.1.2-drop-Python2.patch
new file mode 100644
index 00000000000..82e8b78b242
--- /dev/null
+++ b/dev-python/chai/files/chai-1.1.2-drop-Python2.patch
@@ -0,0 +1,30 @@
+--- a/chai/chai.py
++++ b/chai/chai.py
+@@ -62,11 +62,6 @@
+ try:
+ func(self, *args, **kwargs)
+ except UnexpectedCall as e:
+- # if this is not python3, use python2 syntax
+- if not hasattr(e, '__traceback__'):
+- from .python2 import reraise
+- reraise(
+- AssertionError, '\n\n' + str(e), sys.exc_info()[-1])
+ exc = AssertionError('\n\n' + str(e))
+ setattr(exc, '__traceback__', sys.exc_info()[-1])
+ raise exc
+--- a/chai/python2.py
++++ b/chai/python2.py
+@@ -1,3 +0,0 @@
+-
+-def reraise(exc, msg, traceback):
+- raise exc, msg, traceback
+--- a/chai.egg-info/SOURCES.txt
++++ b/chai.egg-info/SOURCES.txt
+@@ -10,7 +10,6 @@
+ chai/exception.py
+ chai/expectation.py
+ chai/mock.py
+-chai/python2.py
+ chai/spy.py
+ chai/stub.py
+ chai.egg-info/PKG-INFO
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2020-04-10 14:30 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2020-04-10 14:30 [gentoo-commits] repo/gentoo:master commit in: dev-python/chai/files/, dev-python/chai/ Andreas Sturmlechner
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox