From 4cbcc855382a06088e2f016f62cafdbcb7e40665 Mon Sep 17 00:00:00 2001 From: V3n3RiX Date: Sun, 20 Mar 2022 00:40:44 +0000 Subject: gentoo resync : 20.03.2022 --- dev-python/anyio/Manifest | 7 +- dev-python/anyio/anyio-3.2.1.ebuild | 48 -------- dev-python/anyio/anyio-3.4.0.ebuild | 4 +- dev-python/anyio/anyio-3.5.0.ebuild | 7 +- .../anyio/files/anyio-3.2.1-missing-trio.patch | 125 --------------------- 5 files changed, 8 insertions(+), 183 deletions(-) delete mode 100644 dev-python/anyio/anyio-3.2.1.ebuild delete mode 100644 dev-python/anyio/files/anyio-3.2.1-missing-trio.patch (limited to 'dev-python/anyio') diff --git a/dev-python/anyio/Manifest b/dev-python/anyio/Manifest index 3b87c538be2a..0110029c77bb 100644 --- a/dev-python/anyio/Manifest +++ b/dev-python/anyio/Manifest @@ -1,8 +1,5 @@ -AUX anyio-3.2.1-missing-trio.patch 4024 BLAKE2B 7f53d13f07dc1a8fea86c5b9c44a07cd2f2da61159eacbe4043246ada988ab7a57e894b9dbf58185a20f39ada7794268a65ae6868a5f8501bcb363fdf95f776c SHA512 a53ee1bc475f34eb6be535bcde0ed67ed626e6e0576fcfd51ef700370bca3be8bb9c5f89fd69a9de36ce717b05246564f0204e27038f0d48f2ab6039643aeb1c -DIST anyio-3.2.1.tar.gz 126277 BLAKE2B 510980c9251081d5188f7654279753051cd9f8221f2090fb99624612e48b6f5fc1f6d9f1808f1c329c350857f14ceaee0d72615857171de33dc35cc7ba35ab23 SHA512 ef78e5531a917e3a5ddc1106f45ba556ca147e52ab29ed6cb25a3bd287148a15a015942dde6b9535d683fbe5910affed27df6ce5c4049251610f689cd151ee89 DIST anyio-3.4.0.tar.gz 135737 BLAKE2B 6023d051a10a067b8c86576dd80571a64c72a807c56235ecd7bad364b79b10c5b845c6b584c5310db01b3bfdd92deeaf64b855716b9fa817fe2fc590de33ec4c SHA512 276fb5fc243e2c7f80a069f604ef68eeaca923c0df6f533878f9bf2185e846e537a1b9a8f19260a3c9ad3aad70898884316e6783057044a936762f7eb1f1cb9a DIST anyio-3.5.0.tar.gz 136934 BLAKE2B 422d604c23658844467926f42c09895e54debfd3ddf2f7fa561eccae0c9cbc225f51d663cb9f98a2455736ad7a81eb4ae40a6f3ad66f3d2f0b02d0a5157203e0 SHA512 b91124c95d194eb7e4542405a973895d21562a2636d9600d528465da52536d1ffedbf5a6fc3ea5b1ff3e83e7dca2b42f090bb2ff6b077e32f5a2c314f07d3206 -EBUILD anyio-3.2.1.ebuild 1114 BLAKE2B 7abdbaf9ed430fa5925cbe76a4c5e7f3907d13cf009ac5a7eab70547a0e8f6f4ac9512b1ad875b2cf540afd4665c2882c65dee0c07e0df33a359ebd59fee4bf1 SHA512 c3f5682aad78694879395c85e02c3dfe99270c31e01f4c185e00b7f72aa5cadadd3deca2e01a09e23621976cf72984b6a29c4f7e55d4cb18de5d3ae1333875cf -EBUILD anyio-3.4.0.ebuild 1099 BLAKE2B 9c65c3154235572743675700d637f937f783827c6b82431cc9e9cfc7126eb04654c0301fb78922fe2138b97715fc1561229127d656b8e5f0f5d355a8230eb392 SHA512 7ed6955d779e89eb5c3b01c4476264326bd8c16f0d5d4dee7fbe35343171e474e43848610f44fd97abaa21e219b60e80c08f934bdd6fcee6a27581fbec2dc34e -EBUILD anyio-3.5.0.ebuild 1100 BLAKE2B cb98454a3a1f156cec5f8fc1ee021b4bc4f4fbe4e8dced60114454203b0e646cf6c691b63169bee4fca44161d9c1b652caa2af03ab109f1a937ee58f426d1a10 SHA512 de765300dacb7ec40aaf40b9c9655afea154d0088c317b91fb4f61a1f619f69880d4a9b3628078e7413d8310fe80bced04ae648ded294c11008a4068396402e5 +EBUILD anyio-3.4.0.ebuild 1093 BLAKE2B ba828d6d187689d45f44f7e0dfb685f81afa357fea4a4589f94f996c420a6529cff46e1daa4d173581b79d796e148257d6db444289434de882aac2b20d749305 SHA512 5d2e07bf8468f2b9bbfbfde58d0ace51507ac0c6919e851c6fa3c7d7d2b54d51541fce789a1cb6c03c18d2c4bcf4743dd78fb19fc571b4e3f9e658b456f3dbdc +EBUILD anyio-3.5.0.ebuild 1252 BLAKE2B fd4a6f00598610d11999c27def585b210748e2544b03a4a3dc775561bdd7ee9f64c639981c2f1da6f2962580c88e808afee46f9835faf1a832153eb0678406ca SHA512 e231848bc83f73705fc70f78835e4c69e1a0a1591a6115d7f7114b348efa1b01ae79eb187d908f3e8fe24ea6de93014c613a300bb7a7ea1abd0d016ff199f86b MISC metadata.xml 1321 BLAKE2B 22708116b3b04529a83c9e005e421dab21dd5b259df12c3c7e75c74cc3505510b828ebe9808a234ce91d0fc2f17476bf884050561efb18892eb13c35806bbfc1 SHA512 6c1333b6e58faacacf68cd1bd6544c5b28d55ebb75efba1702aa5e2d4f28c29ac86dbbfd45dbb8af1dc2bf69476667d52c7f14bc765d836133e0811c6f2c880e diff --git a/dev-python/anyio/anyio-3.2.1.ebuild b/dev-python/anyio/anyio-3.2.1.ebuild deleted file mode 100644 index 8531185549a0..000000000000 --- a/dev-python/anyio/anyio-3.2.1.ebuild +++ /dev/null @@ -1,48 +0,0 @@ -# Copyright 1999-2021 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI=7 - -PYTHON_COMPAT=( python3_{8..10} ) - -inherit distutils-r1 - -DESCRIPTION="Compatibility layer for multiple asynchronous event loop implementations" -HOMEPAGE=" - https://github.com/agronholm/anyio - https://pypi.org/project/anyio/ -" -SRC_URI="mirror://pypi/${P:0:1}/${PN}/${P}.tar.gz" - -LICENSE="MIT" -SLOT="0" -KEYWORDS="amd64 arm arm64 hppa ppc ppc64 ~riscv sparc x86" - -RDEPEND=" - >=dev-python/idna-2.8[${PYTHON_USEDEP}] - >=dev-python/sniffio-1.1[${PYTHON_USEDEP}] -" - -BDEPEND=" - test? ( - >=dev-python/hypothesis-4.0[${PYTHON_USEDEP}] - >=dev-python/pytest-6.2[${PYTHON_USEDEP}] - >=dev-python/pytest-mock-3.6.1[${PYTHON_USEDEP}] - dev-python/trustme[${PYTHON_USEDEP}] - >=dev-python/uvloop-0.15[${PYTHON_USEDEP}] - ) -" - -distutils_enable_tests --install pytest -distutils_enable_sphinx docs \ - dev-python/sphinx_rtd_theme \ - dev-python/sphinx-autodoc-typehints - -PATCHES=( - "${FILESDIR}"/${P}-missing-trio.patch -) - -python_test() { - distutils_install_for_testing - epytest -Wdefault -m 'not network' -p no:django -} diff --git a/dev-python/anyio/anyio-3.4.0.ebuild b/dev-python/anyio/anyio-3.4.0.ebuild index a3d9afc11b03..e8baabafef7d 100644 --- a/dev-python/anyio/anyio-3.4.0.ebuild +++ b/dev-python/anyio/anyio-3.4.0.ebuild @@ -1,4 +1,4 @@ -# Copyright 1999-2021 Gentoo Authors +# Copyright 1999-2022 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 EAPI=7 @@ -16,7 +16,7 @@ SRC_URI="mirror://pypi/${P:0:1}/${PN}/${P}.tar.gz" LICENSE="MIT" SLOT="0" -KEYWORDS="amd64 ~arm ~arm64 ~hppa ~ppc ~ppc64 ~riscv ~sparc x86" +KEYWORDS="amd64 arm arm64 hppa ppc ppc64 ~riscv sparc x86" RDEPEND=" >=dev-python/idna-2.8[${PYTHON_USEDEP}] diff --git a/dev-python/anyio/anyio-3.5.0.ebuild b/dev-python/anyio/anyio-3.5.0.ebuild index a57dd40c611b..5379b452a5e4 100644 --- a/dev-python/anyio/anyio-3.5.0.ebuild +++ b/dev-python/anyio/anyio-3.5.0.ebuild @@ -15,20 +15,21 @@ SRC_URI="mirror://pypi/${P:0:1}/${PN}/${P}.tar.gz" LICENSE="MIT" SLOT="0" -KEYWORDS="~amd64 ~arm ~arm64 ~hppa ~ppc ~ppc64 ~riscv ~sparc ~x86" +KEYWORDS="amd64 arm arm64 hppa ~ia64 ppc ppc64 ~riscv ~s390 sparc x86" RDEPEND=" >=dev-python/idna-2.8[${PYTHON_USEDEP}] >=dev-python/sniffio-1.1[${PYTHON_USEDEP}] " - +# On amd64, let's get more test coverage by dragging in uvloop, but let's +# not bother on other arches where uvloop may not be supported. BDEPEND=" test? ( >=dev-python/hypothesis-4.0[${PYTHON_USEDEP}] >=dev-python/pytest-6.2[${PYTHON_USEDEP}] >=dev-python/pytest-mock-3.6.1[${PYTHON_USEDEP}] dev-python/trustme[${PYTHON_USEDEP}] - >=dev-python/uvloop-0.15[${PYTHON_USEDEP}] + amd64? ( >=dev-python/uvloop-0.15[${PYTHON_USEDEP}] ) ) " diff --git a/dev-python/anyio/files/anyio-3.2.1-missing-trio.patch b/dev-python/anyio/files/anyio-3.2.1-missing-trio.patch deleted file mode 100644 index 492fe40fe70e..000000000000 --- a/dev-python/anyio/files/anyio-3.2.1-missing-trio.patch +++ /dev/null @@ -1,125 +0,0 @@ -From d05f92bddc4b34a8d527f66d5d27513cd91c741a Mon Sep 17 00:00:00 2001 -From: =?UTF-8?q?Micha=C5=82=20G=C3=B3rny?= -Date: Thu, 24 Jun 2021 09:16:01 +0200 -Subject: [PATCH] Handle missing trio gracefully - -Make it possible to use anyio without actually having to install trio. -This involves modifying get_all_backends() to only return the backends -that are actually present, and teaching the tests to skip trio if it -is not importable. ---- - src/anyio/_core/_eventloop.py | 13 +++++++++---- - tests/conftest.py | 9 ++++++++- - tests/test_pytest_plugin.py | 2 +- - tests/test_taskgroups.py | 10 ++++++++-- - 4 files changed, 26 insertions(+), 8 deletions(-) - -diff --git a/src/anyio/_core/_eventloop.py b/src/anyio/_core/_eventloop.py -index f2364a3..431a922 100644 ---- a/src/anyio/_core/_eventloop.py -+++ b/src/anyio/_core/_eventloop.py -@@ -10,8 +10,6 @@ import sniffio - # This must be updated when new backends are introduced - from ._compat import DeprecatedAwaitableFloat - --BACKENDS = 'asyncio', 'trio' -- - T_Retval = TypeVar('T_Retval') - threadlocals = threading.local() - -@@ -106,8 +104,15 @@ def current_time() -> DeprecatedAwaitableFloat: - - - def get_all_backends() -> Tuple[str, ...]: -- """Return a tuple of the names of all built-in backends.""" -- return BACKENDS -+ """Return a tuple of the names of all available built-in backends.""" -+ backends = ['asyncio'] -+ try: -+ import trio -+ except ImportError: -+ pass -+ else: -+ backends.append(trio) -+ return tuple(backends) - - - def get_cancelled_exc_class() -> Type[BaseException]: -diff --git a/tests/conftest.py b/tests/conftest.py -index f040ac8..5834395 100644 ---- a/tests/conftest.py -+++ b/tests/conftest.py -@@ -8,6 +8,11 @@ import trustme - from _pytest.fixtures import SubRequest - from trustme import CA - -+try: -+ import trio -+except ImportError: -+ trio = None -+ - uvloop_marks = [] - uvloop_policy = None - try: -@@ -30,7 +35,9 @@ pytest_plugins = ['pytester'] - id='asyncio'), - pytest.param(('asyncio', {'debug': True, 'policy': uvloop_policy}), marks=uvloop_marks, - id='asyncio+uvloop'), -- pytest.param('trio') -+ pytest.param('trio', -+ marks=[pytest.mark.skipif(trio is None, -+ reason='trio is not available')]) - ]) - def anyio_backend(request: SubRequest) -> Tuple[str, Dict[str, Any]]: - return request.param -diff --git a/tests/test_pytest_plugin.py b/tests/test_pytest_plugin.py -index bb254a5..d55d511 100644 ---- a/tests/test_pytest_plugin.py -+++ b/tests/test_pytest_plugin.py -@@ -135,7 +135,7 @@ def test_asyncio(testdir: Testdir) -> None: - ) - - result = testdir.runpytest('-v') -- result.assert_outcomes(passed=2, failed=1, errors=2) -+ result.assert_outcomes(passed=2, failed=1, errors=len(get_all_backends())) - - - def test_autouse_async_fixture(testdir: Testdir) -> None: -diff --git a/tests/test_taskgroups.py b/tests/test_taskgroups.py -index 62a2389..47971c0 100644 ---- a/tests/test_taskgroups.py -+++ b/tests/test_taskgroups.py -@@ -5,7 +5,6 @@ import time - from typing import Any, AsyncGenerator, Coroutine, Dict, Generator, NoReturn, Set - - import pytest --import trio - - import anyio - from anyio import ( -@@ -13,6 +12,11 @@ from anyio import ( - fail_after, get_cancelled_exc_class, move_on_after, sleep, wait_all_tasks_blocked) - from anyio.abc import TaskGroup, TaskStatus - -+try: -+ import trio -+except ImportError: -+ trio = None -+ - if sys.version_info < (3, 7): - current_task = asyncio.Task.current_task - else: -@@ -53,7 +57,9 @@ async def test_success() -> None: - - @pytest.mark.parametrize('module', [ - pytest.param(asyncio, id='asyncio'), -- pytest.param(trio, id='trio') -+ pytest.param(trio, id='trio', -+ marks=[pytest.mark.skipif(trio is None, -+ reason='trio is not available')]) - ]) - def test_run_natively(module: Any) -> None: - async def testfunc() -> None: --- -2.32.0 - -- cgit v1.2.3