def run(self):
        try:
            from progressbar import ProgressBar, Bar, Counter, Timer, ETA, Percentage, RotatingMarker
            widgets = [Percentage(), Bar(left='[', right=']'), ' Processed: ', Counter(), '/', "%s" % self.task_count, ' total files (', Timer(), ') ', ETA()]
            pb = ProgressBar(widgets=widgets, maxval=self.task_count).start()
            while self.task_queue.qsize():
                pb.update(self.task_count - self.task_queue.qsize())
                
                time.sleep(0.5)
            pb.finish()
        except KeyboardInterrupt:
            warning("progressbar interrupted by user\n")
            return 1
        except __HOLE__:
            warning("progressbar module not available")
        except:
            warning("unknown error from progress bar")

        return 0
dataset/ETHPy150Open lmco/laikaboss/laika.py/QueueMonitor.run