[issue24296] Queue documentation note needed
![](https://secure.gravatar.com/avatar/fa0f7819f1825f596b384c19aa7dcf33.jpg?s=120&d=mm&r=g)
New submission from Sandy Chapman: The example at the bottom of the following page should have a warning added: https://docs.python.org/2/library/queue.html The warning should be such that the user is informed that the threads in the example are not cleaned up and will continue to run. Any future additions to the queue will then be processed immediately by those threads. ---------- assignee: docs@python components: Documentation messages: 244156 nosy: Sandy Chapman, docs@python priority: normal severity: normal status: open title: Queue documentation note needed _______________________________________ Python tracker <report@bugs.python.org> <http://bugs.python.org/issue24296> _______________________________________
![](https://secure.gravatar.com/avatar/fa0f7819f1825f596b384c19aa7dcf33.jpg?s=120&d=mm&r=g)
R. David Murray added the comment: If you know anything about threads you can see that the threads are not explicitly shut down. As a standalone example it is "correct", in that they get shut down at interpreter shutdown. I'm not sure it is appropriate to include what is essentially a thread tutorial note in the queue docs. A crosslink to threading would certainly be a good idea; perhaps the introductory sentence could be tweaked to point people who don't already know threads in the correct direction for enlightenment. ---------- nosy: +r.david.murray _______________________________________ Python tracker <report@bugs.python.org> <http://bugs.python.org/issue24296> _______________________________________
![](https://secure.gravatar.com/avatar/fa0f7819f1825f596b384c19aa7dcf33.jpg?s=120&d=mm&r=g)
Changes by Raymond Hettinger <raymond.hettinger@gmail.com>: ---------- assignee: docs@python -> rhettinger nosy: +rhettinger _______________________________________ Python tracker <report@bugs.python.org> <http://bugs.python.org/issue24296> _______________________________________
![](https://secure.gravatar.com/avatar/fa0f7819f1825f596b384c19aa7dcf33.jpg?s=120&d=mm&r=g)
Raymond Hettinger added the comment: It is normal for daemon threads to not be shut down. That is why they exist. The purpose of Queue.join() is to give other threads a way to know when daemons have finished doing their work (i.e. a print manager thread to indicate that it is done printing). If the worker threads were actually going to terminate, you wouldn't need Queue.join(), you would use a Thread.join(). ---------- _______________________________________ Python tracker <report@bugs.python.org> <http://bugs.python.org/issue24296> _______________________________________
![](https://secure.gravatar.com/avatar/fa0f7819f1825f596b384c19aa7dcf33.jpg?s=120&d=mm&r=g)
Changes by Raymond Hettinger <raymond.hettinger@gmail.com>: ---------- resolution: -> not a bug status: open -> closed _______________________________________ Python tracker <report@bugs.python.org> <http://bugs.python.org/issue24296> _______________________________________
participants (3)
-
R. David Murray
-
Raymond Hettinger
-
Sandy Chapman