homepage

This issue tracker has been migrated to GitHub , and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author patrick.vrijlandt
Recipients patrick.vrijlandt
Date 2011年05月03日.19:30:07
SpamBayes Score 5.430401e-06
Marked as misclassified No
Message-id <1304451008.79.0.490801283429.issue11987@psf.upfronthosting.co.za>
In-reply-to
Content
Line 154 in standard library's queue.py, in the definition of Queue.put() is: 
self.unfinished_tasks += 1
This line should be protected by acquiring the all_tasks_done lock.
Theoretically, the increment could occur somewhere during task_done()!
Additional note:
Personally, I would like the increment to occur *before* instead of *after* _put(). This is because I would like to be able to implement a _put() that does not put everything. This put should be able to undo the increment. As it is, calling task_done() from put might decrease the counter to zero inadvertently.
History
Date User Action Args
2011年05月03日 19:30:08patrick.vrijlandtsetrecipients: + patrick.vrijlandt
2011年05月03日 19:30:08patrick.vrijlandtsetmessageid: <1304451008.79.0.490801283429.issue11987@psf.upfronthosting.co.za>
2011年05月03日 19:30:08patrick.vrijlandtlinkissue11987 messages
2011年05月03日 19:30:07patrick.vrijlandtcreate

AltStyle によって変換されたページ (->オリジナル) /