summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJustin Lecher <jlec@gentoo.org>2015-10-20 14:26:47 +0200
committerJustin Lecher <jlec@gentoo.org>2015-10-21 15:40:24 +0200
commiteb80eef434d30057ca8e61222e15175e7853c6fe (patch)
treef328c0d8e97e38c4871666bbc9cc3fdceb70272c /dev-python/pycurl
parentdev-python/bottleneck: Add python3.5 support (diff)
downloadgentoo-eb80eef434d30057ca8e61222e15175e7853c6fe.tar.gz
gentoo-eb80eef434d30057ca8e61222e15175e7853c6fe.tar.bz2
gentoo-eb80eef434d30057ca8e61222e15175e7853c6fe.zip
dev-python/pycurl: Backport fix for py3.5
fixes Github: pycurl/pycurl/#273 Github: pycurl/pycurl/#274 Package-Manager: portage-2.2.23 Signed-off-by: Justin Lecher <jlec@gentoo.org>
Diffstat (limited to 'dev-python/pycurl')
-rw-r--r--dev-python/pycurl/files/pycurl-7.19.5.1-py3.5-backport.patch15
-rw-r--r--dev-python/pycurl/pycurl-7.19.5.1-r1.ebuild4
2 files changed, 19 insertions, 0 deletions
diff --git a/dev-python/pycurl/files/pycurl-7.19.5.1-py3.5-backport.patch b/dev-python/pycurl/files/pycurl-7.19.5.1-py3.5-backport.patch
new file mode 100644
index 000000000000..0bc6f6c3b56b
--- /dev/null
+++ b/dev-python/pycurl/files/pycurl-7.19.5.1-py3.5-backport.patch
@@ -0,0 +1,15 @@
+ tests/memory_mgmt_test.py | 4 +++-
+ 1 file changed, 3 insertions(+), 1 deletion(-)
+
+diff --git a/tests/memory_mgmt_test.py b/tests/memory_mgmt_test.py
+index 08636ae..a7b8a21 100644
+--- a/tests/memory_mgmt_test.py
++++ b/tests/memory_mgmt_test.py
+@@ -258,4 +258,6 @@ class MemoryMgmtTest(unittest.TestCase):
+
+ gc.collect()
+ new_object_count = len(gc.get_objects())
+- self.assertEqual(new_object_count, object_count)
++ # it seems that GC sometimes collects something that existed
++ # before this test ran, GH issues #273/#274
++ self.assertTrue(new_object_count in (object_count, object_count-1))
diff --git a/dev-python/pycurl/pycurl-7.19.5.1-r1.ebuild b/dev-python/pycurl/pycurl-7.19.5.1-r1.ebuild
index a96f734aa3a8..5f3041c3d838 100644
--- a/dev-python/pycurl/pycurl-7.19.5.1-r1.ebuild
+++ b/dev-python/pycurl/pycurl-7.19.5.1-r1.ebuild
@@ -40,6 +40,10 @@ DEPEND="${RDEPEND}
# Needed for individual runs of testsuite by python impls.
DISTUTILS_IN_SOURCE_BUILD=1
+PATCHES=(
+ "${FILESDIR}"/${P}-py3.5-backport.patch
+)
+
python_prepare_all() {
sed -e "/setup_args\['data_files'\] = /d" -i setup.py || die
distutils-r1_python_prepare_all