python-aiounittest fails to build with Python 3.11.0a2. ====================================================================== ERROR: Failure: AttributeError (module 'asyncio' has no attribute 'coroutine') ---------------------------------------------------------------------- Traceback (most recent call last): File "/usr/lib/python3.11/site-packages/nose/failure.py", line 39, in runTest raise self.exc_val.with_traceback(self.tb) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.11/site-packages/nose/loader.py", line 416, in loadTestsFromName module = self.importer.importFromPath( ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.11/site-packages/nose/importer.py", line 47, in importFromPath return self.importFromDir(dir_path, fqname) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.11/site-packages/nose/importer.py", line 94, in importFromDir mod = load_module(part_fqname, fh, filename, desc) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib64/python3.11/imp.py", line 235, in load_module return load_source(name, filename, file) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib64/python3.11/imp.py", line 172, in load_source module = _load(spec) ^^^^^^^^^^^ File "<frozen importlib._bootstrap>", line 721, in _load File "<frozen importlib._bootstrap>", line 690, in _load_unlocked File "<frozen importlib._bootstrap_external>", line 897, in exec_module File "<frozen importlib._bootstrap>", line 241, in _call_with_frames_removed File "/builddir/build/BUILD/aiounittest-1.3.1/tests/test_asynctestcase.py", line 24, in <module> class TestAsyncCase(aiounittest.AsyncTestCase): ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/builddir/build/BUILD/aiounittest-1.3.1/tests/test_asynctestcase.py", line 40, in TestAsyncCase @asyncio.coroutine ^^^^^^^^^^^^^^^^^ AttributeError: module 'asyncio' has no attribute 'coroutine' ====================================================================== ERROR: Failure: AttributeError (module 'asyncio' has no attribute 'coroutine') ---------------------------------------------------------------------- Traceback (most recent call last): File "/usr/lib/python3.11/site-packages/nose/failure.py", line 39, in runTest raise self.exc_val.with_traceback(self.tb) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.11/site-packages/nose/loader.py", line 416, in loadTestsFromName module = self.importer.importFromPath( ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.11/site-packages/nose/importer.py", line 47, in importFromPath return self.importFromDir(dir_path, fqname) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3.11/site-packages/nose/importer.py", line 94, in importFromDir mod = load_module(part_fqname, fh, filename, desc) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib64/python3.11/imp.py", line 235, in load_module return load_source(name, filename, file) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib64/python3.11/imp.py", line 172, in load_source module = _load(spec) ^^^^^^^^^^^ File "<frozen importlib._bootstrap>", line 721, in _load File "<frozen importlib._bootstrap>", line 690, in _load_unlocked File "<frozen importlib._bootstrap_external>", line 897, in exec_module File "<frozen importlib._bootstrap>", line 241, in _call_with_frames_removed File "/builddir/build/BUILD/aiounittest-1.3.1/tests/test_asynctestcase_get_event_loop.py", line 26, in <module> class TestAsyncCaseWithCustomLoop(aiounittest.AsyncTestCase): ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/builddir/build/BUILD/aiounittest-1.3.1/tests/test_asynctestcase_get_event_loop.py", line 37, in TestAsyncCaseWithCustomLoop @asyncio.coroutine ^^^^^^^^^^^^^^^^^ AttributeError: module 'asyncio' has no attribute 'coroutine' ---------------------------------------------------------------------- Ran 7 tests in 0.226s FAILED (errors=2) The @asyncio.coroutine decorator enabling legacy generator-based coroutines to be compatible with async/await code. The function has been deprecated since Python 3.8 and the removal was initially scheduled for Python 3.10. Use async def instead. (Contributed by Illia Volochii in bpo-43216.) https://bugs.python.org/issue43216 https://docs.python.org/3.11/whatsnew/3.11.html For the build logs, see: https://copr-be.cloud.fedoraproject.org/results/@python/python3.11/fedora-rawhide-x86_64/02984473-python-aiounittest/ For all our attempts to build python-aiounittest with Python 3.11, see: https://copr.fedorainfracloud.org/coprs/g/python/python3.11/package/python-aiounittest/ Testing and mass rebuild of packages is happening in copr. You can follow these instructions to test locally in mock if your package builds with Python 3.11: https://copr.fedorainfracloud.org/coprs/g/python/python3.11/ Let us know here if you have any questions. Python 3.11 is planned to be included in Fedora 37. To make that update smoother, we're building Fedora packages with all pre-releases of Python 3.11. A build failure prevents us from testing all dependent packages (transitive [Build]Requires), so if this package is required a lot, it's important for us to get it fixed soon. We'd appreciate help from the people who know this package best, but if you don't want to work on this now, let us know so we can try to work around it on our side.
This bug appears to have been reported against 'rawhide' during the Fedora 36 development cycle. Changing version to 36.
This now blocks the rebuild of python-aiosqlite -> python-starlette (-> python-databases) -> python-authlib -> bodhi-client -> fedpkg Hence, sending severity to high.
It looks like the tests explicitly test for @asyncio.coroutine and need to be if-ed out.
Upstream: https://github.com/kwarunek/aiounittest/pull/21 Downstream: https://src.fedoraproject.org/rpms/python-aiounittest/pull-request/1 One problem remains: ERROR: test_await_async_add (test_asynctestcase_get_event_loop.TestAsyncCaseWithCustomLoop.test_await_async_add) ---------------------------------------------------------------------- Traceback (most recent call last): File "/builddir/build/BUILD/aiounittest-1.3.1/aiounittest/helpers.py", line 137, in wrapper future = asyncio.ensure_future(ret, loop=loop) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib64/python3.11/asyncio/tasks.py", line 658, in ensure_future return _ensure_future(coro_or_future, loop=loop) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib64/python3.11/asyncio/tasks.py", line 679, in _ensure_future return loop.create_task(coro_or_future) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/lib64/python3.11/asyncio/base_events.py", line 434, in create_task self._check_closed() ^^^^^^^^^^^^^^^^^^^^ File "/usr/lib64/python3.11/asyncio/base_events.py", line 519, in _check_closed raise RuntimeError('Event loop is closed') ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ RuntimeError: Event loop is closed
Workaround in https://src.fedoraproject.org/rpms/python-aiounittest/pull-request/1
Real fix in https://src.fedoraproject.org/rpms/python-aiounittest/pull-request/1
Closing this in bulk as it built with Python 3.11. If this needs to remain open for a followup, feel free to reopen, I won't close in bulk again.