Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Using set_max_refresh_rate prevents bar from updating, is not defeated by tick/flush #118

Open
ZoomRmc opened this issue Apr 22, 2023 · 0 comments

Comments

@ZoomRmc
Copy link

ZoomRmc commented Apr 22, 2023

In my case, I'd like to set the bar to the exact final total number in case the process doesn't go to completion.
No combination of set/tick/flush does get me an updated state when the ProgressBar goes out of scope.

Looks like there's no final redraw upon exiting the thread. At first I though it might be some kind of a race condition, so checked with sleeping the main thread to no avail.

Some possible solutions in order of preference:

  • Make flush or tick ignore the refresh rate.
  • Expose a manual redraw.
  • Add a finish_with(final: u64) - not ideal, as the ProgressBar.count is not public (why?), which means a duplicating variable is necessary on user's side.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant