Commit 28a3c5a8 authored by Dion Häfner's avatar Dion Häfner
Browse files

[util] fix progress test

parent 265ed089
...@@ -96,6 +96,10 @@ class FancyProgressBar: ...@@ -96,6 +96,10 @@ class FancyProgressBar:
We only need TQDM to handle dynamic updates to the progress indicator. We only need TQDM to handle dynamic updates to the progress indicator.
""" """
def __init__(self, *args, **kwargs):
kwargs.update(leave=True)
super().__init__(*args, **kwargs)
@property @property
def format_dict(other): def format_dict(other):
report_time = time.convert_time(self._time, 'seconds', self._time_unit) report_time = time.convert_time(self._time, 'seconds', self._time_unit)
...@@ -152,7 +156,6 @@ class FancyProgressBar: ...@@ -152,7 +156,6 @@ class FancyProgressBar:
def __exit__(self, *args, **kwargs): def __exit__(self, *args, **kwargs):
logs.setup_logging(loglevel=rs.loglevel) logs.setup_logging(loglevel=rs.loglevel)
self._pbar.__exit__(*args, **kwargs)
def advance_time(self, amount): def advance_time(self, amount):
self._iteration += 1 self._iteration += 1
...@@ -160,7 +163,7 @@ class FancyProgressBar: ...@@ -160,7 +163,7 @@ class FancyProgressBar:
self.flush() self.flush()
def flush(self): def flush(self):
self._pbar.update(0) self._pbar.refresh()
def get_progress_bar(vs, use_tqdm=None): def get_progress_bar(vs, use_tqdm=None):
......
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