This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

classification
Title: test_coroutines generates some warnings
Type: behavior Stage: resolved
Components: Versions: Python 3.6, Python 3.5
process
Status: closed Resolution: fixed
Dependencies: Superseder:
Assigned To: yselivanov Nosy List: benjamin.peterson, giampaolo.rodola, gvanrossum, python-dev, vstinner, xiang.zhang, yselivanov
Priority: normal Keywords:

Created on 2016-09-06 06:29 by xiang.zhang, last changed 2022-04-11 14:58 by admin. This issue is now closed.

Pull Requests
URL Status Linked Edit
PR 5410 yselivanov, 2018-01-29 06:25
Messages (8)
msg274529 - (view) Author: Xiang Zhang (xiang.zhang) * (Python committer) Date: 2016-09-06 06:29
./python -m test test_coroutines
Run tests sequentially
0:00:00 [1/1] test_coroutines
/home/angwer/cpython/Lib/test/test_coroutines.py:891: RuntimeWarning: coroutine 'CoroutineTest.test_await_12.<locals>.coro' was never awaited
  return await Awaitable()
/home/angwer/cpython/Lib/test/test_coroutines.py:35: RuntimeWarning: coroutine 'CoroutineTest.test_await_9.<locals>.bar' was never awaited
  buffer.append(coro.send(None))
Exception ignored in: <coroutine object CoroutineTest.test_fatal_coro_warning.<locals>.func at 0x7f481378f678>
RuntimeWarning: coroutine 'CoroutineTest.test_fatal_coro_warning.<locals>.fun' was never awaited
Exception ignored in: <coroutine object CoroutineTest.test_for_10.<locals>.AI.__aiter__ at 0x7f481378f5c8>
RuntimeWarning: coroutine 'CoroutineTest.test_for_10.<locals>.AI.__aiter__' was never awaited
Exception ignored in: <coroutine object CoroutineTest.test_for_9.<locals>.AI.__aiter__ at 0x7f481378f5c8>
RuntimeWarning: coroutine 'CoroutineTest.test_for_9.<locals>.AI.__aiter__' was never awaited
/home/angwer/cpython/Lib/test/test_coroutines.py:555: RuntimeWarning: coroutine 'CoroutineTest.test_func_13.<locals>.g' was never awaited
  g().send('spam')
/home/angwer/cpython/Lib/test/test_coroutines.py:408: RuntimeWarning: coroutine 'CoroutineTest.test_func_4.<locals>.foo' was never awaited
  list(foo())
/home/angwer/cpython/Lib/test/test_coroutines.py:411: RuntimeWarning: coroutine 'CoroutineTest.test_func_4.<locals>.foo' was never awaited
  tuple(foo())
/home/angwer/cpython/Lib/test/test_coroutines.py:414: RuntimeWarning: coroutine 'CoroutineTest.test_func_4.<locals>.foo' was never awaited
  sum(foo())
/home/angwer/cpython/Lib/test/test_coroutines.py:417: RuntimeWarning: coroutine 'CoroutineTest.test_func_4.<locals>.foo' was never awaited
  iter(foo())
/home/angwer/cpython/Lib/test/test_coroutines.py:438: RuntimeWarning: coroutine 'CoroutineTest.test_func_5.<locals>.foo' was never awaited
  for el in foo(): pass
1 test OK.

Total duration: 290 ms
Tests result: SUCCESS
msg274752 - (view) Author: Guido van Rossum (gvanrossum) * (Python committer) Date: 2016-09-07 04:22
I only have a Mac to test -- does anyone else on this issue have a Linux system to try to reproduce this?
msg274753 - (view) Author: Guido van Rossum (gvanrossum) * (Python committer) Date: 2016-09-07 04:25
NM I get the same on Mac after rebuilding from scratch. I can repro this with the 3.5 branch too. Wonder if something changed in asyncio?
msg274757 - (view) Author: Guido van Rossum (gvanrossum) * (Python committer) Date: 2016-09-07 04:30
Yury this smells of something in async/await?
msg274759 - (view) Author: Xiang Zhang (xiang.zhang) * (Python committer) Date: 2016-09-07 04:50
Run hg bisect and get 756c27efe193.
msg274823 - (view) Author: Roundup Robot (python-dev) (Python triager) Date: 2016-09-07 15:47
New changeset 234f758449f8 by Benjamin Peterson in branch '3.5':
supress coroutine warning when an exception is pending (#27968)
https://hg.python.org/cpython/rev/234f758449f8

New changeset f48b00b1ec4f by Benjamin Peterson in branch 'default':
merge 3.5 (#27968)
https://hg.python.org/cpython/rev/f48b00b1ec4f
msg274825 - (view) Author: Roundup Robot (python-dev) (Python triager) Date: 2016-09-07 16:01
New changeset 096dfac57e44 by Benjamin Peterson in branch '3.5':
capture stderr to silence output during test_coroutines (closes #27968)
https://hg.python.org/cpython/rev/096dfac57e44

New changeset b43923ce86f0 by Benjamin Peterson in branch 'default':
merge 3.5 (closes #27968)
https://hg.python.org/cpython/rev/b43923ce86f0
msg274835 - (view) Author: Guido van Rossum (gvanrossum) * (Python committer) Date: 2016-09-07 16:51
Thanks Benjamin!
History
Date User Action Args
2022-04-11 14:58:35adminsetgithub: 72155
2018-01-29 06:25:32yselivanovsetpull_requests: + pull_request5245
2016-09-07 16:51:01gvanrossumsetmessages: + msg274835
2016-09-07 16:01:08python-devsetstatus: open -> closed
resolution: fixed
messages: + msg274825

stage: resolved
2016-09-07 15:47:45python-devsetnosy: + python-dev
messages: + msg274823
2016-09-07 04:50:41xiang.zhangsetnosy: + benjamin.peterson
messages: + msg274759
2016-09-07 04:30:19gvanrossumsetassignee: yselivanov
messages: + msg274757
2016-09-07 04:25:38gvanrossumsetmessages: + msg274753
versions: + Python 3.5
2016-09-07 04:22:56gvanrossumsetmessages: + msg274752
2016-09-06 06:29:11xiang.zhangcreate