Message300567
| Author | ncoghlan |
|---|---|
| Recipients | JohanAR, davin, gvanrossum, itamarst, ncoghlan, pitrou, python-dev, rhettinger, sbt, serhiy.storchaka, tim.peters, yselivanov, zzzeek |
| Date | 2017-08-19.06:46:07 |
| SpamBayes Score | -1.0 |
| Marked as misclassified | Yes |
| Message-id | <1503125167.85.0.586983899276.issue14976@psf.upfronthosting.co.za> |
| In-reply-to |
| Content | |
|---|---|
+1 for treating Queue.put() specifically as the case to be handled, as that's the mechanism that can be used to *avoid* running complex operations directly in __del__ methods and weakref callbacks. For testing purposes, the current deadlock can be reliably reproduced with sys.settrace: ``` >>> import sys >>> import queue >>> the_queue=queue.Queue() >>> counter = 0 >>> def bad_trace(*args): ... global counter ... counter += 1 ... print(counter) ... the_queue.put(counter) ... return bad_trace ... >>> sys.settrace(bad_trace) >>> the_queue.put(None) 1 2 3 4 5 6 7 [and here we have a deadlock] ``` |
|
| History | |||
|---|---|---|---|
| Date | User | Action | Args |
| 2017-08-19 06:46:08 | ncoghlan | set | recipients: + ncoghlan, gvanrossum, tim.peters, rhettinger, pitrou, zzzeek, python-dev, sbt, serhiy.storchaka, JohanAR, yselivanov, itamarst, davin |
| 2017-08-19 06:46:07 | ncoghlan | set | messageid: <1503125167.85.0.586983899276.issue14976@psf.upfronthosting.co.za> |
| 2017-08-19 06:46:07 | ncoghlan | link | issue14976 messages |
| 2017-08-19 06:46:07 | ncoghlan | create | |