Commits

angri  committed 687c1cb

taskhandle: increment `self.done` before informing observers.
Because self.done is incremented after `self.handle._inform_observers()`
an observing function will never see `JobSet.get_percent_done() == 100`.
Thanks to dysiode for reporting.

  • Participants
  • Parent commits 7c1afff

Comments (0)

Files changed (1)

File rope/base/taskhandle.py

 
     def finished_job(self):
         self.check_status()
+        self.done += 1
         self.handle._inform_observers()
         self.job_name = None
-        self.done += 1
 
     def check_status(self):
         if self.handle.is_stopped():