Message206713
| Author |
vstinner |
| Recipients |
gvanrossum, pitrou, vstinner |
| Date |
2013年12月20日.22:37:14 |
| SpamBayes Score |
-1.0 |
| Marked as misclassified |
Yes |
| Message-id |
<1387579034.42.0.639565765322.issue20032@psf.upfronthosting.co.za> |
| In-reply-to |
| Content |
"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. |
|
History
|
|---|
| Date |
User |
Action |
Args |
| 2013年12月20日 22:37:14 | vstinner | set | recipients:
+ vstinner, gvanrossum, pitrou |
| 2013年12月20日 22:37:14 | vstinner | set | messageid: <1387579034.42.0.639565765322.issue20032@psf.upfronthosting.co.za> |
| 2013年12月20日 22:37:14 | vstinner | link | issue20032 messages |
| 2013年12月20日 22:37:14 | vstinner | create |
|