[New-bugs-announce] [issue47076] test_asyncio: test_get_cancelled() fails randomly on x86-64 macOS 3.x

STINNER Victor report at bugs.python.org
Sun Mar 20 23:14:47 EDT 2022


New submission from STINNER Victor <vstinner at python.org>:

x86-64 macOS 3.x failures:

* https://buildbot.python.org/all/#/builders/366/builds/2085
* https://buildbot.python.org/all/#/builders/366/builds/2078
* https://buildbot.python.org/all/#/builders/366/builds/2077
* https://buildbot.python.org/all/#/builders/366/builds/2073
* https://buildbot.python.org/all/#/builders/366/builds/2072
* https://buildbot.python.org/all/#/builders/366/builds/2069

Logs:
---
0:18:33 load avg: 2.21 Re-running test_asyncio in verbose mode (matching: test_get_cancelled)
test_get_cancelled (test.test_asyncio.test_queues.QueueGetTests) ... ERROR

======================================================================
ERROR: test_get_cancelled (test.test_asyncio.test_queues.QueueGetTests)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/Users/buildbot/buildarea/3.x.billenstein-macos/build/Lib/asyncio/tasks.py", line 490, in wait_for
    return fut.result()
           ^^^^^^^^^^^^
  File "/Users/buildbot/buildarea/3.x.billenstein-macos/build/Lib/asyncio/queues.py", line 158, in get
    await getter
    ^^^^^^^^^^^^
asyncio.exceptions.CancelledError

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
  File "/Users/buildbot/buildarea/3.x.billenstein-macos/build/Lib/unittest/async_case.py", line 66, in _callTestMethod
    if self._callMaybeAsync(method) is not None:
       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/buildbot/buildarea/3.x.billenstein-macos/build/Lib/unittest/async_case.py", line 93, in _callMaybeAsync
    return self._asyncioTestLoop.run_until_complete(task)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/buildbot/buildarea/3.x.billenstein-macos/build/Lib/asyncio/base_events.py", line 650, in run_until_complete
    return future.result()
           ^^^^^^^^^^^^^^^
  File "/Users/buildbot/buildarea/3.x.billenstein-macos/build/Lib/test/test_asyncio/test_queues.py", line 179, in test_get_cancelled
    self.assertEqual(1, await get_task)
                        ^^^^^^^^^^^^^^
  File "/Users/buildbot/buildarea/3.x.billenstein-macos/build/Lib/test/test_asyncio/test_queues.py", line 174, in queue_get
    return await asyncio.wait_for(q.get(), 0.051)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/buildbot/buildarea/3.x.billenstein-macos/build/Lib/asyncio/tasks.py", line 492, in wait_for
    raise exceptions.TimeoutError() from exc
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
TimeoutError
---


Recent change related to this test:

commit e707ceb6e464b24ddc9fdbdac7bfe15f7eeb43fd
Author: Andrew Svetlov <andrew.svetlov at gmail.com>
Date:   Wed Mar 16 16:59:12 2022 +0200

    Rewrite asyncio.Queue tests with IsolatedAsyncioTestCace (#31935)

----------
components: Tests, asyncio
messages: 415653
nosy: asvetlov, vstinner, yselivanov
priority: normal
severity: normal
status: open
title: test_asyncio: test_get_cancelled() fails randomly on x86-64 macOS 3.x
versions: Python 3.11

_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue47076>
_______________________________________


More information about the New-bugs-announce mailing list