STINNER Victor added the comment:

"The cycle will be cleaned up (and the message printed) when the
garbage collector runs next."

Oh, ok. Using the following task, the object is correctly deleted.
---
@asyncio.coroutine
def idle():
    while 1:
        gc.collect()
        yield from asyncio.sleep(0.1)

asyncio.Task(idle())
---

"Maybe it's time to look into
http://code.google.com/p/tulip/issues/detail?id=42 ? (It proposes to
run gc.collect() occasionally when the loop is idle.)"

I don't like such task. The issue can be documented, maybe with an example of 
call calling gc.collect() regulary? Such background task should be implemented 
in the application to control when the garbage collector is called.

----------

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

Reply via email to