You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
100% (100 of 100) |#######################| Elapsed Time: 0:00:02 Time: 0:00:02
The reason is that the wrapper around the iterable calls self.update(self.value + 1) but self.value is not updated if the time from last update is less than _MINIMUM_UPDATE_INTERVAL.
Code
Just added print statement to example code from documentation to show the mismatch between internal value and actual iteration.
import time
import progressbar
bar = progressbar.ProgressBar()
for i in bar(range(100)):
print(i, bar.value)
time.sleep(0.02)
Description
Progressbar as wrapped iterable show to high ETA if iterations take less than _MINIMUM_UPDATE_INTERVAL.
The example code from the documentation jumps from
to
The reason is that the wrapper around the iterable calls
self.update(self.value + 1)but self.value is not updated if the time from last update is less than_MINIMUM_UPDATE_INTERVAL.Code
Just added print statement to example code from documentation to show the mismatch between internal value and actual iteration.
Versions