diff options
Diffstat (limited to 'dev-python/twisted')
-rw-r--r-- | dev-python/twisted/Manifest | 8 | ||||
-rw-r--r-- | dev-python/twisted/files/twisted-22.1.0-force-gtk3.patch | 67 | ||||
-rw-r--r-- | dev-python/twisted/files/twisted-22.10.0-python3.11-tests.patch | 100 | ||||
-rw-r--r-- | dev-python/twisted/files/twisted-22.10.0-sendmail.patch | 28 | ||||
-rw-r--r-- | dev-python/twisted/twisted-22.10.0-r1.ebuild | 169 | ||||
-rw-r--r-- | dev-python/twisted/twisted-22.10.0-r3.ebuild | 173 | ||||
-rw-r--r-- | dev-python/twisted/twisted-23.8.0_rc1.ebuild | 154 |
7 files changed, 0 insertions, 699 deletions
diff --git a/dev-python/twisted/Manifest b/dev-python/twisted/Manifest index 291771813d42..a99488f6f540 100644 --- a/dev-python/twisted/Manifest +++ b/dev-python/twisted/Manifest @@ -1,15 +1,7 @@ AUX twistd.conf 277 BLAKE2B 78ca35b410a6597c9afe6a9c8d3dfb1de113411634901f936794e8a59c0644233d0673e710bd0870ecf4312d079c46f62f43928605700559134f1fb62490559a SHA512 76d44caebab8404f16937c2515ad9ae8236732a48c7127366f7fa22c6ed3d88ace2d33b832a6d95f775973d41b7caf75344805fe5b01e964c04eb710bf3c89fb AUX twistd.init 563 BLAKE2B 24488118b025bf2068bbf07af900064ff6a7ee99106c3da30f15f2b3f85af7443212afebc6b52a12645488b85656f87b653df9263fc2be6bd09707917899f252 SHA512 7860601beba1efda2b0a045b2a044ec33caff9ee915d45225c05e281760a68da349b4c45080600177aab32aa806714327acf3cf5dda92be0874f781f129bb129 -AUX twisted-22.1.0-force-gtk3.patch 2634 BLAKE2B bf297589d56a59149e1a269aef416a9aef26dd2123cd9fc87358d19b279bd2924e84d3e9fffe5e6edb70f7268c19b4053cfdf6362b04dd6e91b3a2c997e0f92f SHA512 85b1678cf6c73e78004a015424f2e092b42bf4f5899ed607093b4c26ff1411fe22267df09c331f80086f9d46e5a6dadfad7fe62cbb04e3edeaaa05f40c96239a -AUX twisted-22.10.0-python3.11-tests.patch 4144 BLAKE2B d4e645419d82787a5e411204572186c4759026eec94190928a7db6d45667a427e3caa82d22d85ac94c8d764671d96fba69b7f948ddb5d7054068166e5727b04c SHA512 78fdf42bb552fbdb2951c50d5a80b97d3c46fd08789f7f09923edc0087d35ee4564b5698a2f32f4630276a00a9eeabcbfb44e61a78d3ff7e241fdc5f432dc911 -AUX twisted-22.10.0-sendmail.patch 1045 BLAKE2B 4566f4fcecd6d79d43af52bfba4b9953c718458b8832871111b86255fa1b4cadddbc5b588bc61422cb41bf6facfe22d812106c32c912914f263d37cbb05ee6a6 SHA512 9ddb2416c730260e31bcd49584449ddf3172382de129613173c57e0360d2d1ae920870e74c3ed1edb19951b460ddb51ec0719b974d9142e8bbd6a42fea9cbbd9 AUX twisted-22.10.0-time.patch 4275 BLAKE2B d8f4f79163aba42494c4f753f915df2611b3fd3f0dd26448087e9bc0b56be0fd1047a0a4e518e07846a6bbae14529590f057411528e8ca8464d122c6b5b08684 SHA512 e92be2938aca686e4cf2557d05287bf1b52cc4f57290ebc4d1942ad6894d148f7dd3072158b6249a0952b4bbb8ec221150ff81d162bd797a97eabde8b5f047b6 -DIST twisted-22.10.0.gh.tar.gz 3512714 BLAKE2B 2fd36ec6922f428e959ce0169bb9a3592b8b3e43aff8d34872883ecf0fad8d0fff01a52f06b54df3dc377f4fc1a488b6d66f9287b108b4749bb7d3c749b96061 SHA512 cf9ed96430376d499ae9627a7d0656c05cb99bc9e9b15a8f4166355363818f090bc3c2b383ed4cf19e1e38fb569e8618d35a0ddde2a90a06f3c9a4ea769837e4 DIST twisted-23.8.0.tar.gz 3478691 BLAKE2B 44fa9da691456a2b1d97f54b95787abe3e162b5639ee7ab8779c6d9525eb2a878865f450aa6fd6c461c3eba84f95361d2423e241991f52f91a27b792b6d71123 SHA512 ef0a243a4c22dd31e57087f5b2c21a657b98e23cc486f08b9926a9ebe8c4b6fec137993aea71e6c60abc3d653d995da0f65ff10dfc6c3d2cb7fdae5db08e2532 -DIST twisted-23.8.0rc1.tar.gz 3479000 BLAKE2B d3dbc54759f4dcba422cbcc57451a268834f21616ea2b5d34d972f2647750afa4ae62424ae32b2e0fe22e3a886c45ff1e64280c99553aa1ee52923a192773fdf SHA512 a1e778247a311dda30cd7f9f02fa4ab8848d6d5b89de4ff83dee5a92f968b6ec8df48d1804eef780cd0a9dc1393a1a91d624e9c54e0c9cd52d930ac2b36a0b6c DIST twisted-regen-cache.gz 911 BLAKE2B ffd3fcda6c67ffe6fd3ef581c8d507548396b66ed0708e9a5c790095e579c0d5f0f71596acf05712989da2ddef2b8d437eca973bc4d80ef8a9fa852915f38305 SHA512 95a9b931c73017d16d1b5e6b41345dddffe62b6af1a8e93b5e40d06d3d15be17b0dd0181c767ffeeb791534d463764ef9e066fa6c2ee2ac4b53c86d1da8fce03 -EBUILD twisted-22.10.0-r1.ebuild 4786 BLAKE2B c8e38c998613aa0e22c6b8e3253d336d02c8290cdbce55fe0e561ed021ad575fdd235df6601e10446893f46c1731dc923f58afd03359e673eef3fed54694ebc4 SHA512 d6bc65f955c3cb9228b8bd7bc84bca51f99e614680eb5d34cf99939af1fc696be11c04cee6766dce7d0a6475c12f2fd82d0a2a084c73e25380c823a6b71263ae -EBUILD twisted-22.10.0-r3.ebuild 4955 BLAKE2B 6fbc79e6e5d8cf74d2a22b77d0d06832342afc44521acabcb4fcda40f2dff816f0db7e62ef757401eb6929f576e1eea8eecf6db8042bae2a8808db1e5946c84e SHA512 f34b474c87e159b51bfc8cf9806cce8ca26f00ca44e353d104657878d84e8ae860bfa15649b6cb3eaa44ec3a0e7a0e2178d4086a5652d113f7d1ed4431dbeb67 EBUILD twisted-23.8.0.ebuild 4184 BLAKE2B ca39e9e3ba7489dd781c1673eede3a51a5fd3047d19448f018770030872cad95d7607d2dedc1f72b40d9882fb7a232fa42af6ceee306b4609cfa9ae6a44edf7a SHA512 ed0db98a2d1db6fb24459fab25cb7439ac987e7acc1ca507cb2e15b1da4c6367ffd2b96eb3b970d9970922756fdb5166e6ed1351c64a553d3cd41d072ab9e817 -EBUILD twisted-23.8.0_rc1.ebuild 4192 BLAKE2B 287dd90c4ed51dd259ab3710543a8c9ee39b7ef43120f30868f716da3664261573a86562aa4e7282de2a5f9461bc2c51c73e6e0d1b0ef42371e63a3afc9e9044 SHA512 3cdc4f58b7ab29d557cd719f064eae282de0020e3854e001b41e5c207e202cef40f067996beeaeda495c93f832984f9a2b3dab54d42bfbd344f77b33872ac9ce MISC metadata.xml 1281 BLAKE2B 06f3bba5716e641cfb848eaf212fcd5a18d89caeefe1b0ec2fc6e0799ded9ded5c54dc04d239b6e7c427a23c0300caecc67cbb2a292a745dba5cddbf02fe4330 SHA512 e78734d016205a2bd850ddf68bfefce024a95efc4d4a42af52314aa363d6c654dada671b98a1b02642e7abe2f9a48c0454949b4bf07e88776924c63175b24227 diff --git a/dev-python/twisted/files/twisted-22.1.0-force-gtk3.patch b/dev-python/twisted/files/twisted-22.1.0-force-gtk3.patch deleted file mode 100644 index 7c9f2d558d65..000000000000 --- a/dev-python/twisted/files/twisted-22.1.0-force-gtk3.patch +++ /dev/null @@ -1,67 +0,0 @@ -From 9344f8cd80ecb2907dbfddfeeb8cc9ffdb50bc94 Mon Sep 17 00:00:00 2001 -From: =?UTF-8?q?Micha=C5=82=20G=C3=B3rny?= <mgorny@gentoo.org> -Date: Sat, 22 May 2021 01:11:48 +0200 -Subject: [PATCH] Force using GTK+3 in twisted.internet.gireactor - -Modify twisted.internet.gireactor to explicitly request GTK+ version 3. -Otherwise it uses the newest version installed which could be GTK+4 -that gireactor is currently incompatible with. ---- - src/twisted/internet/gireactor.py | 3 +++ - src/twisted/internet/test/test_gireactor.py | 3 +++ - src/twisted/newsfragments/10200.bugfix | 1 + - 3 files changed, 7 insertions(+) - create mode 100644 src/twisted/newsfragments/10200.bugfix - -diff --git a/src/twisted/internet/gireactor.py b/src/twisted/internet/gireactor.py -index e2d24b599..838fa982e 100644 ---- a/src/twisted/internet/gireactor.py -+++ b/src/twisted/internet/gireactor.py -@@ -21,6 +21,7 @@ On Python 3, pygobject v3.4 or later is required. - """ - - -+import gi # type: ignore[import] - import gi.pygtkcompat # type: ignore[import] - from gi.repository import GLib # type: ignore[import] - -@@ -69,6 +70,7 @@ class GIReactor(_glibbase.GlibReactorBase): - def __init__(self, useGtk=False): - _gtk = None - if useGtk is True: -+ gi.require_version("Gtk", "3.0") - from gi.repository import Gtk as _gtk - - _glibbase.GlibReactorBase.__init__(self, GLib, _gtk, useGtk=useGtk) -@@ -113,6 +115,7 @@ class PortableGIReactor(_glibbase.PortableGlibReactorBase): - def __init__(self, useGtk=False): - _gtk = None - if useGtk is True: -+ gi.require_version("Gtk", "3.0") - from gi.repository import Gtk as _gtk - - _glibbase.PortableGlibReactorBase.__init__(self, GLib, _gtk, useGtk=useGtk) -diff --git a/src/twisted/internet/test/test_gireactor.py b/src/twisted/internet/test/test_gireactor.py -index c25ada63f..3bb88a07f 100644 ---- a/src/twisted/internet/test/test_gireactor.py -+++ b/src/twisted/internet/test/test_gireactor.py -@@ -26,6 +26,9 @@ else: - gtk3reactor = None - else: - gtk3reactor = _gtk3reactor -+ import gi # type: ignore[import] -+ -+ gi.require_version("Gtk", "3.0") - from gi.repository import Gtk - - from twisted.internet.error import ReactorAlreadyRunning -diff --git a/src/twisted/newsfragments/10200.bugfix b/src/twisted/newsfragments/10200.bugfix -new file mode 100644 -index 000000000..7afb343be ---- /dev/null -+++ b/src/twisted/newsfragments/10200.bugfix -@@ -0,0 +1 @@ -+twisted.internet.gireactor was fixed to force GTK+3 in order to fix use of incompatible GTK+4 API when installed --- -2.35.1 - diff --git a/dev-python/twisted/files/twisted-22.10.0-python3.11-tests.patch b/dev-python/twisted/files/twisted-22.10.0-python3.11-tests.patch deleted file mode 100644 index b75c97d4997f..000000000000 --- a/dev-python/twisted/files/twisted-22.10.0-python3.11-tests.patch +++ /dev/null @@ -1,100 +0,0 @@ -https://src.fedoraproject.org/rpms/python-twisted/blob/rawhide/f/0003-Fix-tests-for-Python-3.11.patch - -From b0574816f622bc187389df2183e2bef0492fe5f5 Mon Sep 17 00:00:00 2001 -From: eevel <eevel@weezel3.weezelnet> -Date: Wed, 2 Nov 2022 20:35:55 -0500 -Subject: [PATCH 3/6] Fix tests for Python 3.11 - -This is based on a subset of commits from this pull request. - -https://github.com/twisted/twisted/pull/11734 - -- fix twisted.persisted tests (cherry picked from commit 4f6d7fb0749429b092fe7538a7d2b11fe58319a6) -- fix tests for twisted.spread (cherry picked from commit 525377178adfa987ed56be753aec0fce35d721dc) -- fix test for twisted.web (cherry picked from commit afcc224a02f72e5d12fa35d223bd753e8086b135) -- fix persisted tests in twisted.test (cherry picked from commit 4b5ab38b09b326cec7967e04bd4cae8a84bb6784) -- fix twisted.trial tests (cherry picked from commit f8f56d45113e5f2467a5e8375186e5db6309dfc6) -- make test_flatten backwards-compatible (cherry picked from commit d91675ac5ffe907fcdbb3d1cedb1240008d81fd1) ---- a/src/twisted/persisted/aot.py -+++ b/src/twisted/persisted/aot.py -@@ -399,8 +399,10 @@ class AOTUnjellier: - inst = klass.__new__(klass) - if hasattr(klass, "__setstate__"): - self.callAfter(inst.__setstate__, state) -- else: -+ elif isinstance(state, dict): - inst.__dict__ = state -+ else: -+ inst.__dict__ = state.__getstate__() - return inst - - elif c is Ref: ---- a/src/twisted/spread/flavors.py -+++ b/src/twisted/spread/flavors.py -@@ -398,6 +398,8 @@ class RemoteCopy(Unjellyable): - object's dictionary (or a filtered approximation of it depending - on my peer's perspective). - """ -+ if not state: -+ state = {} - state = { - x.decode("utf8") if isinstance(x, bytes) else x: y for x, y in state.items() - } ---- a/src/twisted/spread/jelly.py -+++ b/src/twisted/spread/jelly.py -@@ -154,7 +154,8 @@ def _newInstance(cls, state): - instance = _createBlank(cls) - - def defaultSetter(state): -- instance.__dict__ = state -+ if isinstance(state, dict): -+ instance.__dict__ = state or {} - - setter = getattr(instance, "__setstate__", defaultSetter) - setter(state) ---- a/src/twisted/test/test_persisted.py -+++ b/src/twisted/test/test_persisted.py -@@ -378,6 +378,10 @@ class AOTTests(TestCase): - def __dict__(self): - raise AttributeError() - -+ @property -+ def __getstate__(self): -+ raise AttributeError() -+ - self.assertRaises(TypeError, aot.jellyToSource, UnknownType()) - - def test_basicIdentity(self): ---- a/src/twisted/trial/test/test_pyunitcompat.py -+++ b/src/twisted/trial/test/test_pyunitcompat.py -@@ -218,8 +218,10 @@ class PyUnitResultTests(SynchronousTestCase): - pyresult = pyunit.TestResult() - result = PyUnitResultAdapter(pyresult) - result.addError(self, f) -+ tback = "".join(traceback.format_exception(*exc_info)) - self.assertEqual( -- pyresult.errors[0][1], "".join(traceback.format_exception(*exc_info)) -+ pyresult.errors[0][1].endswith("ZeroDivisionError: division by zero\n"), -+ tback.endswith("ZeroDivisionError: division by zero\n"), - ) - - def test_trialSkip(self): ---- a/src/twisted/web/test/test_flatten.py -+++ b/src/twisted/web/test/test_flatten.py -@@ -706,10 +706,9 @@ class FlattenerErrorTests(SynchronousTestCase): - Exception while flattening: - \\[<unrenderable>\\] - <unrenderable> -- .* -+ <Deferred at .* current result: <twisted.python.failure.Failure builtins.RuntimeError: example>> - File ".*", line \\d*, in _flattenTree -- element = await element -- RuntimeError: example -+ element = await element.* - """ - ), - flags=re.MULTILINE, --- -2.39.2 - - diff --git a/dev-python/twisted/files/twisted-22.10.0-sendmail.patch b/dev-python/twisted/files/twisted-22.10.0-sendmail.patch deleted file mode 100644 index eec57752815d..000000000000 --- a/dev-python/twisted/files/twisted-22.10.0-sendmail.patch +++ /dev/null @@ -1,28 +0,0 @@ -https://src.fedoraproject.org/rpms/python-twisted/raw/rawhide/f/0005-fix-sendmail-tests-for-python-3.11.patch - -From f29ae1ae433cd9529410a93fd5675cb01460460e Mon Sep 17 00:00:00 2001 -From: eevel <eevel@weezel3.weezelnet> -Date: Wed, 26 Oct 2022 19:49:33 -0500 -Subject: [PATCH 5/6] fix sendmail tests for python 3.11 - -(cherry picked from commit 00bf5be704bee022ba4d9b24eb6c2c768b4a1921) ---- a/src/twisted/mail/test/test_smtp.py -+++ b/src/twisted/mail/test/test_smtp.py -@@ -1771,7 +1771,8 @@ class SendmailTests(TestCase): - The default C{reactor} parameter of L{twisted.mail.smtp.sendmail} is - L{twisted.internet.reactor}. - """ -- args, varArgs, keywords, defaults = inspect.getargspec(smtp.sendmail) -+ fullSpec = inspect.getfullargspec(smtp.sendmail) -+ defaults = fullSpec[3] - self.assertEqual(reactor, defaults[2]) - - def _honorsESMTPArguments(self, username, password): ---- /dev/null -+++ b/src/twisted/newsfragments/10345.misc -@@ -0,0 +1 @@ -+Fix SendmailTests for python 3.11. --- -2.39.2 - - diff --git a/dev-python/twisted/twisted-22.10.0-r1.ebuild b/dev-python/twisted/twisted-22.10.0-r1.ebuild deleted file mode 100644 index 2857f4759871..000000000000 --- a/dev-python/twisted/twisted-22.10.0-r1.ebuild +++ /dev/null @@ -1,169 +0,0 @@ -# Copyright 1999-2023 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI=8 - -DISTUTILS_USE_PEP517=setuptools -PYTHON_COMPAT=( python3_{9..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 -> ${P}.gh.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.8.0[${PYTHON_USEDEP}] - >=dev-python/constantly-15.1[${PYTHON_USEDEP}] - >=dev-python/hyperlink-17.1.1[${PYTHON_USEDEP}] - >=dev-python/incremental-21.3.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-3.0.0[${PYTHON_USEDEP}] - >=dev-python/cryptography-2.6[${PYTHON_USEDEP}] - dev-python/pyasn1[${PYTHON_USEDEP}] - ) - http2? ( - <dev-python/h2-5.0.0[${PYTHON_USEDEP}] - >=dev-python/h2-3.0.0[${PYTHON_USEDEP}] - <dev-python/priority-2.0[${PYTHON_USEDEP}] - >=dev-python/priority-1.1.0[${PYTHON_USEDEP}] - ) - serial? ( - >=dev-python/pyserial-3.0[${PYTHON_USEDEP}] - ) - ssl? ( - >=dev-python/pyopenssl-21.0.0[${PYTHON_USEDEP}] - >=dev-python/service-identity-18.1.0[${PYTHON_USEDEP}] - >=dev-python/idna-2.4[${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-1.0.2[${PYTHON_USEDEP}] - >=dev-python/idna-2.4[${PYTHON_USEDEP}] - dev-python/hypothesis[${PYTHON_USEDEP}] - dev-python/pyasn1[${PYTHON_USEDEP}] - >=dev-python/pyhamcrest-1.9.0[${PYTHON_USEDEP}] - >=dev-python/pyserial-3.0[${PYTHON_USEDEP}] - virtual/openssh - conch? ( - >=dev-python/bcrypt-3.0.0[${PYTHON_USEDEP}] - >=dev-python/cryptography-2.6[${PYTHON_USEDEP}] - ) - ssl? ( - >=dev-python/pyopenssl-21.0.0[${PYTHON_USEDEP}] - >=dev-python/service-identity-18.1.0[${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" -) - -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 -} diff --git a/dev-python/twisted/twisted-22.10.0-r3.ebuild b/dev-python/twisted/twisted-22.10.0-r3.ebuild deleted file mode 100644 index 4d56b83d2585..000000000000 --- a/dev-python/twisted/twisted-22.10.0-r3.ebuild +++ /dev/null @@ -1,173 +0,0 @@ -# Copyright 1999-2023 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI=8 - -DISTUTILS_USE_PEP517=setuptools -PYTHON_TESTED=( python3_{10..11} pypy3 ) -PYTHON_COMPAT=( "${PYTHON_TESTED[@]}" python3_12 ) -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 -> ${P}.gh.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 ~arm64-macos ~x64-macos" -IUSE="conch http2 serial ssl test" -RESTRICT="!test? ( test )" - -RDEPEND=" - >=dev-python/attrs-19.2.0[${PYTHON_USEDEP}] - >=dev-python/automat-0.8.0[${PYTHON_USEDEP}] - >=dev-python/constantly-15.1[${PYTHON_USEDEP}] - >=dev-python/hyperlink-17.1.1[${PYTHON_USEDEP}] - >=dev-python/incremental-21.3.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-3.0.0[${PYTHON_USEDEP}] - >=dev-python/cryptography-2.6[${PYTHON_USEDEP}] - dev-python/pyasn1[${PYTHON_USEDEP}] - ) - http2? ( - <dev-python/h2-5.0.0[${PYTHON_USEDEP}] - >=dev-python/h2-3.0.0[${PYTHON_USEDEP}] - <dev-python/priority-2.0[${PYTHON_USEDEP}] - >=dev-python/priority-1.1.0[${PYTHON_USEDEP}] - ) - serial? ( - >=dev-python/pyserial-3.0[${PYTHON_USEDEP}] - ) - ssl? ( - >=dev-python/pyopenssl-21.0.0[${PYTHON_USEDEP}] - >=dev-python/service-identity-18.1.0[${PYTHON_USEDEP}] - >=dev-python/idna-2.4[${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-1.0.2[${PYTHON_USEDEP}] - >=dev-python/idna-2.4[${PYTHON_USEDEP}] - dev-python/hypothesis[${PYTHON_USEDEP}] - dev-python/pyasn1[${PYTHON_USEDEP}] - >=dev-python/pyhamcrest-1.9.0[${PYTHON_USEDEP}] - >=dev-python/pyserial-3.0[${PYTHON_USEDEP}] - virtual/openssh - conch? ( - >=dev-python/bcrypt-3.0.0[${PYTHON_USEDEP}] - >=dev-python/cryptography-2.6[${PYTHON_USEDEP}] - ) - ssl? ( - >=dev-python/pyopenssl-21.0.0[${PYTHON_USEDEP}] - >=dev-python/service-identity-18.1.0[${PYTHON_USEDEP}] - ) - ' "${PYTHON_TESTED[@]}") - $(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" - - "${FILESDIR}/${PN}-22.10.0-python3.11-tests.patch" - "${FILESDIR}/${PN}-22.10.0-time.patch" - "${FILESDIR}/${PN}-22.10.0-sendmail.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() { - if ! has "${EPYTHON}" "${PYTHON_TESTED[@]/_/.}"; 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 -} diff --git a/dev-python/twisted/twisted-23.8.0_rc1.ebuild b/dev-python/twisted/twisted-23.8.0_rc1.ebuild deleted file mode 100644 index bdb064ec3895..000000000000 --- a/dev-python/twisted/twisted-23.8.0_rc1.ebuild +++ /dev/null @@ -1,154 +0,0 @@ -# Copyright 1999-2023 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI=8 - -DISTUTILS_USE_PEP517=hatchling -PYTHON_TESTED=( python3_{10..12} pypy3 ) -PYTHON_COMPAT=( "${PYTHON_TESTED[@]}" ) -PYTHON_REQ_USE="threads(+)" - -inherit distutils-r1 pypi virtualx - -DESCRIPTION="An asynchronous networking framework written in Python" -HOMEPAGE=" - https://twisted.org/ - https://github.com/twisted/twisted/ - https://pypi.org/project/Twisted/ -" -SRC_URI+=" - https://dev.gentoo.org/~mgorny/dist/twisted-regen-cache.gz -" - -LICENSE="MIT" -SLOT="0" -KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~loong ~m68k ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~arm64-macos ~x64-macos" -IUSE="conch http2 serial ssl test" -RESTRICT="!test? ( test )" - -RDEPEND=" - >=dev-python/attrs-19.2.0[${PYTHON_USEDEP}] - >=dev-python/automat-0.8.0[${PYTHON_USEDEP}] - >=dev-python/constantly-15.1[${PYTHON_USEDEP}] - >=dev-python/hyperlink-17.1.1[${PYTHON_USEDEP}] - >=dev-python/incremental-22.10.0[${PYTHON_USEDEP}] - >=dev-python/typing-extensions-3.10.0[${PYTHON_USEDEP}] - >=dev-python/zope-interface-5[${PYTHON_USEDEP}] - conch? ( - >=dev-python/appdirs-1.4.0[${PYTHON_USEDEP}] - >=dev-python/bcrypt-3.0.0[${PYTHON_USEDEP}] - >=dev-python/cryptography-3.3[${PYTHON_USEDEP}] - dev-python/pyasn1[${PYTHON_USEDEP}] - ) - http2? ( - <dev-python/h2-5.0[${PYTHON_USEDEP}] - >=dev-python/h2-3.0.0[${PYTHON_USEDEP}] - <dev-python/priority-2.0[${PYTHON_USEDEP}] - >=dev-python/priority-1.1.0[${PYTHON_USEDEP}] - ) - serial? ( - >=dev-python/pyserial-3.0[${PYTHON_USEDEP}] - ) - ssl? ( - >=dev-python/pyopenssl-21.0.0[${PYTHON_USEDEP}] - >=dev-python/service-identity-18.1.0[${PYTHON_USEDEP}] - >=dev-python/idna-2.4[${PYTHON_USEDEP}] - ) -" -BDEPEND=" - >=dev-python/hatch-fancy-pypi-readme-22.5.0[${PYTHON_USEDEP}] - >=dev-python/incremental-22.10.0[${PYTHON_USEDEP}] - test? ( - ${RDEPEND} - $(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-2[${PYTHON_USEDEP}] - >=dev-python/cython-test-exception-raiser-1.0.2[${PYTHON_USEDEP}] - >=dev-python/idna-2.4[${PYTHON_USEDEP}] - >=dev-python/hypothesis-6.56[${PYTHON_USEDEP}] - dev-python/pyasn1[${PYTHON_USEDEP}] - >=dev-python/pyhamcrest-2[${PYTHON_USEDEP}] - >=dev-python/pyserial-3.0[${PYTHON_USEDEP}] - virtual/openssh - ssl? ( - >=dev-python/pyopenssl-21.0.0[${PYTHON_USEDEP}] - >=dev-python/service-identity-18.1.0[${PYTHON_USEDEP}] - ) - ' "${PYTHON_TESTED[@]}") - ) -" - -PATCHES=( - # https://github.com/twisted/twisted/pull/11787 - "${FILESDIR}/${PN}-22.10.0-time.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 - - # 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 - - 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() { - if ! has "${EPYTHON}" "${PYTHON_TESTED[@]/_/.}"; 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 -} |