diff options
author | Michał Górny <mgorny@gentoo.org> | 2022-10-11 09:19:55 +0200 |
---|---|---|
committer | Michał Górny <mgorny@gentoo.org> | 2022-10-11 09:19:55 +0200 |
commit | b453f4789c869b73d454e3ea5d17dc126c4d0680 (patch) | |
tree | 5268eea88dde62d2b16a0962832893875c0725df /dev-python/twisted | |
parent | dev-python/dulwich: Remove old (diff) | |
download | gentoo-b453f4789c869b73d454e3ea5d17dc126c4d0680.tar.gz gentoo-b453f4789c869b73d454e3ea5d17dc126c4d0680.tar.bz2 gentoo-b453f4789c869b73d454e3ea5d17dc126c4d0680.zip |
dev-python/twisted: Remove old
Signed-off-by: Michał Górny <mgorny@gentoo.org>
Diffstat (limited to 'dev-python/twisted')
-rw-r--r-- | dev-python/twisted/Manifest | 1 | ||||
-rw-r--r-- | dev-python/twisted/files/twisted-22.4.0-py311.patch | 55 | ||||
-rw-r--r-- | dev-python/twisted/twisted-22.4.0-r2.ebuild | 168 |
3 files changed, 0 insertions, 224 deletions
diff --git a/dev-python/twisted/Manifest b/dev-python/twisted/Manifest index 63b80aae3084..35a9df374cd8 100644 --- a/dev-python/twisted/Manifest +++ b/dev-python/twisted/Manifest @@ -1,3 +1,2 @@ -DIST twisted-22.4.0.tar.gz 3896724 BLAKE2B 830a724156473a28394e6c731f6cec184c491410dc880bc2e37a99cb460c7fe040219463f224941532b12478abe953aa0228c70676e5baecda4a3b2bdd6a0a32 SHA512 776d36040bcefb9ca65e471d9058fe1067ffc8171a501cb451e9d4824a88dd83f79dc9b27a127ca898451587454ee661000acbce6c4c39b069aeadd64710f103 DIST twisted-22.8.0.gh.tar.gz 3937858 BLAKE2B de5f56f2ac92db3ccd29122f3c3bacc01de325e4b00b60a0ea9bcf13c5714487d596299990d292758821e242443d8c65cda03b895196df0a635b0739f08668fc SHA512 890a11ca55fd88636f404678c6fad3fcea9d0604b1b37681a4b92ea74952bc4d1b96a571dde39a4aa82d966121156801f6b42dbd0bb5a309503591a7a77c6d71 DIST twisted-regen-cache.gz 911 BLAKE2B ffd3fcda6c67ffe6fd3ef581c8d507548396b66ed0708e9a5c790095e579c0d5f0f71596acf05712989da2ddef2b8d437eca973bc4d80ef8a9fa852915f38305 SHA512 95a9b931c73017d16d1b5e6b41345dddffe62b6af1a8e93b5e40d06d3d15be17b0dd0181c767ffeeb791534d463764ef9e066fa6c2ee2ac4b53c86d1da8fce03 diff --git a/dev-python/twisted/files/twisted-22.4.0-py311.patch b/dev-python/twisted/files/twisted-22.4.0-py311.patch deleted file mode 100644 index ed8ded87d4de..000000000000 --- a/dev-python/twisted/files/twisted-22.4.0-py311.patch +++ /dev/null @@ -1,55 +0,0 @@ -From 074fc742a699278ea5266b34aace1e34049b3de3 Mon Sep 17 00:00:00 2001 -From: Colin Watson <cjwatson@canonical.com> -Date: Sat, 23 Apr 2022 22:29:07 +0100 -Subject: [PATCH] Implement twisted.python.failure._Code.co_positions - -This is needed for compatibility with Python 3.11. ---- - src/twisted/newsfragments/10336.bugfix | 1 + - src/twisted/python/failure.py | 5 ++++- - src/twisted/test/test_failure.py | 1 + - 3 files changed, 6 insertions(+), 1 deletion(-) - create mode 100644 src/twisted/newsfragments/10336.bugfix - -diff --git a/src/twisted/newsfragments/10336.bugfix b/src/twisted/newsfragments/10336.bugfix -new file mode 100644 -index 00000000000..a7ffab3627d ---- /dev/null -+++ b/src/twisted/newsfragments/10336.bugfix -@@ -0,0 +1 @@ -+Implement twisted.python.failure._Code.co_positions for compatibility with Python 3.11. -diff --git a/src/twisted/python/failure.py b/src/twisted/python/failure.py -index 6471e7bca59..c5a359e405b 100644 ---- a/src/twisted/python/failure.py -+++ b/src/twisted/python/failure.py -@@ -130,7 +130,7 @@ def _Traceback(stackFrames, tbFrames): - - - # The set of attributes for _TracebackFrame, _Frame and _Code were taken from --# https://docs.python.org/3.10/library/inspect.html Other Pythons may have a -+# https://docs.python.org/3.11/library/inspect.html Other Pythons may have a - # few more attributes that should be added if needed. - class _TracebackFrame: - """ -@@ -202,6 +202,9 @@ def __init__(self, name, filename): - self.co_nlocals = 0 - self.co_stacksize = 0 - -+ def co_positions(self): -+ return ((None, None, None, None),) -+ - - _inlineCallbacksExtraneous = [] - -diff --git a/src/twisted/test/test_failure.py b/src/twisted/test/test_failure.py -index 6dd7c682bf9..6fd82c868ec 100644 ---- a/src/twisted/test/test_failure.py -+++ b/src/twisted/test/test_failure.py -@@ -825,6 +825,7 @@ def test_fakeCodeAttributes(self): - self.assertIsInstance(code.co_nlocals, int) - self.assertIsInstance(code.co_stacksize, int) - self.assertIsInstance(code.co_varnames, list) -+ self.assertIsInstance(code.co_positions(), tuple) - - def test_fakeTracebackFrame(self): - """ diff --git a/dev-python/twisted/twisted-22.4.0-r2.ebuild b/dev-python/twisted/twisted-22.4.0-r2.ebuild deleted file mode 100644 index 5acedaa99e6a..000000000000 --- a/dev-python/twisted/twisted-22.4.0-r2.ebuild +++ /dev/null @@ -1,168 +0,0 @@ -# Copyright 1999-2022 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI=8 - -DISTUTILS_USE_PEP517=setuptools -PYTHON_COMPAT=( python3_{8..11} pypy3 ) -PYTHON_REQ_USE="threads(+)" - -inherit distutils-r1 virtualx - -DESCRIPTION="An asynchronous networking framework written in Python" -HOMEPAGE="https://www.twistedmatrix.com/trac/" -SRC_URI=" - https://github.com/twisted/twisted/archive/${P}.tar.gz - https://dev.gentoo.org/~mgorny/dist/twisted-regen-cache.gz -" -S=${WORKDIR}/${PN}-${P} - -LICENSE="MIT" -SLOT="0" -KEYWORDS="~alpha amd64 arm arm64 hppa ~ia64 ~loong ~m68k ppc ppc64 ~riscv ~s390 sparc x86" -IUSE="conch http2 serial ssl test" -RESTRICT="!test? ( test )" - -RDEPEND=" - >=dev-python/attrs-19.2.0[${PYTHON_USEDEP}] - >=dev-python/automat-0.3.0[${PYTHON_USEDEP}] - >=dev-python/constantly-15.1.0[${PYTHON_USEDEP}] - >=dev-python/hyperlink-17.1.1[${PYTHON_USEDEP}] - >=dev-python/incremental-21.3.0[${PYTHON_USEDEP}] - >=dev-python/pyhamcrest-1.9.0[${PYTHON_USEDEP}] - >=dev-python/typing-extensions-3.6.5[${PYTHON_USEDEP}] - >=dev-python/zope-interface-4.4.2[${PYTHON_USEDEP}] - conch? ( - >=dev-python/appdirs-1.4.0[${PYTHON_USEDEP}] - dev-python/bcrypt[${PYTHON_USEDEP}] - >=dev-python/cryptography-1.5.0[${PYTHON_USEDEP}] - dev-python/pyasn1[${PYTHON_USEDEP}] - ) - http2? ( - >=dev-python/h2-3.0.0[${PYTHON_USEDEP}] - <dev-python/h2-5.0.0[${PYTHON_USEDEP}] - >=dev-python/priority-1.1.0[${PYTHON_USEDEP}] - <dev-python/priority-2.0[${PYTHON_USEDEP}] - ) - serial? ( >=dev-python/pyserial-3.0[${PYTHON_USEDEP}] ) - ssl? ( - >=dev-python/pyopenssl-16.0.0[${PYTHON_USEDEP}] - dev-python/service_identity[${PYTHON_USEDEP}] - >=dev-python/idna-0.6[${PYTHON_USEDEP}] - ) -" -BDEPEND=" - >=dev-python/incremental-21.3.0[${PYTHON_USEDEP}] - test? ( - $(python_gen_cond_dep ' - >=dev-python/appdirs-1.4.0[${PYTHON_USEDEP}] - >=dev-python/constantly-15.1.0[${PYTHON_USEDEP}] - dev-python/cython-test-exception-raiser[${PYTHON_USEDEP}] - dev-python/idna[${PYTHON_USEDEP}] - dev-python/pyasn1[${PYTHON_USEDEP}] - dev-python/pyserial[${PYTHON_USEDEP}] - net-misc/openssh - conch? ( - dev-python/bcrypt[${PYTHON_USEDEP}] - >=dev-python/cryptography-1.5.0[${PYTHON_USEDEP}] - ) - ssl? ( - >=dev-python/pyopenssl-16.0.0[${PYTHON_USEDEP}] - dev-python/service_identity[${PYTHON_USEDEP}] - ) - ' python3_{8..10} pypy3) - $(python_gen_cond_dep ' - dev-python/gmpy[${PYTHON_USEDEP}] - ' python3_{8..10}) - ) -" - -PATCHES=( - # https://twistedmatrix.com/trac/ticket/10200 - "${FILESDIR}/${PN}-22.1.0-force-gtk3.patch" - # https://github.com/twisted/twisted/pull/1723 - "${FILESDIR}/${P}-py311.patch" -) - -python_prepare_all() { - # upstream test for making releases; not very useful and requires - # sphinx (including on py2) - rm src/twisted/python/test/test_release.py || die - - # puts system in EMFILE state, then the exception handler may fail - # trying to open more files due to some gi magic - sed -e '/SKIP_EMFILE/s:False:True:' \ - -i src/twisted/internet/test/test_tcp.py || die - - # multicast tests fail within network-sandbox - sed -e 's:test_joinLeave:_&:' \ - -e 's:test_loopback:_&:' \ - -e 's:test_multiListen:_&:' \ - -e 's:test_multicast:_&:' \ - -i src/twisted/test/test_udp.py || die - - # These tests rely on warnings which seems work unreliably between python versions - sed -e 's:test_currentEUID:_&:' \ - -e 's:test_currentUID:_&:' -i src/twisted/python/test/test_util.py || die - - # broken by new expat - sed -e 's:test_namespaceWithWhitespace:_&:' \ - -i src/twisted/words/test/test_domish.py || die - - distutils-r1_python_prepare_all -} - -src_test() { - # the test suite handles missing file & failing ioctl()s gracefully - # but not permission errors from sandbox - addwrite /dev/net/tun - virtx distutils-r1_src_test -} - -python_test() { - # please keep in sync with python_gen_cond_dep! - if ! has "${EPYTHON}" python3_{8..10} pypy3; then - einfo "Skipping tests on ${EPYTHON} (xfail)" - return - fi - - "${EPYTHON}" -m twisted.trial twisted || - die "Tests failed with ${EPYTHON}" -} - -python_install() { - distutils-r1_python_install - - # own the dropin.cache so we don't leave orphans - > "${D}$(python_get_sitedir)"/twisted/plugins/dropin.cache || die - - python_doscript "${WORKDIR}"/twisted-regen-cache -} - -python_install_all() { - distutils-r1_python_install_all - - newconfd "${FILESDIR}/twistd.conf" twistd - newinitd "${FILESDIR}/twistd.init" twistd -} - -python_postinst() { - twisted-regen-cache || die -} - -pkg_postinst() { - if [[ -z ${ROOT} ]]; then - python_foreach_impl python_postinst - fi -} - -python_postrm() { - rm -f "${ROOT}$(python_get_sitedir)/twisted/plugins/dropin.cache" || die -} - -pkg_postrm() { - # if we're removing the last version, remove the cache file - if [[ ! ${REPLACING_VERSIONS} ]]; then - python_foreach_impl python_postrm - fi -} |