New submission from Nick Coghlan <ncogh...@gmail.com>:

The task management API in the Queue module doesn't let you check to see if 
there are any pending tasks still being processed.

A pending() query API (analagous to empty() and full()) would resolve that 
problem.

The use case is for a process that terminates when all current jobs are 
complete, but should immediately start processing any *new* jobs that arrive 
while waiting for the old ones. Using the current Queue.join() method would 
fail the second requirement (since the blocking calls means that no new jobs 
could be added while waiting for the old ones to finish).

----------
messages: 157453
nosy: ncoghlan
priority: normal
severity: normal
status: open
title: Add pending() query method to Queue.Queue

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

Reply via email to