Commit 218cb230 authored by Denis Bilenko's avatar Denis Bilenko

fix bug in JoinableQueue(0) unfinished_tasks counter was updated too late

parent 93c6f7f3
......@@ -284,8 +284,8 @@ class JoinableQueue(Queue):
result += ' tasks=%s _cond=%s' % (self.unfinished_tasks, self._cond)
return result
def put(self, item, block=True, timeout=None):
Queue.put(self, item, block, timeout)
def _put(self, item):
Queue._put(self, item)
self.unfinished_tasks += 1
self._cond.clear()
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment