Skip to content

Commit

Permalink
fix progress not initialized bug
Browse files Browse the repository at this point in the history
  • Loading branch information
GreatYYX committed May 6, 2020
1 parent d841110 commit 54e3e6c
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion pyrallel/parallel_processor.py
Original file line number Diff line number Diff line change
Expand Up @@ -295,7 +295,8 @@ def add_task(self, *args, **kwargs):
(main process, unblocked, using round robin to find next available queue)
"""
self.batch_data.append((args, kwargs))
self.progress_thread.progress_info[ProgressThread.P_ADDED] += 1
if self.progress:
self.progress_thread.progress_info[ProgressThread.P_ADDED] += 1

if len(self.batch_data) == self.batch_size:
self._add_task(self.batch_data)
Expand Down

0 comments on commit 54e3e6c

Please sign in to comment.