Remove task_done since we never call queue.join.

This commit is contained in:
voussoir 2021-11-20 18:48:40 -08:00
parent 039ac45e17
commit 6d9300aa9d
No known key found for this signature in database
GPG key ID: 5F7554F8C26DACCB

View file

@ -338,11 +338,9 @@ class ThreadPool:
while self._jobs_available.is_set() or not self._result_queue.empty():
job = self._result_queue.get()
if job is NO_MORE_JOBS:
self._result_queue.task_done()
break
job.join()
yield job
self._result_queue.task_done()
self._result_queue = None
if was_paused: