New submission from STINNER Victor:

Attached script stops immediatly whereas I would expect that the second call to 
run_forever() keeps running. If you execute the script, you will see:

deque([<Handle _raise_stop_error() at 
/home/haypo/prog/python/default/Lib/asyncio/base_events.py:94>])

The first call to run_forever() keeps a pending call to loop.stop() (to 
_rase_stop_error() in fact).

I don't know if it should be called a bug or if this surprising behaviour 
should be documented.

See also the issue #22428.

----------
components: asyncio
files: pending_stop.py
messages: 226994
nosy: gvanrossum, haypo, yselivanov
priority: normal
severity: normal
status: open
title: asyncio: pending call to loop.stop() if a coroutine raises a 
BaseException
versions: Python 3.4, Python 3.5
Added file: http://bugs.python.org/file36637/pending_stop.py

_______________________________________
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue22429>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to