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

Fix showing full percentage progress before metadata download start #158

Merged
merged 2 commits into from
Nov 14, 2022

Conversation

jan-kolarik
Copy link
Member

@jan-kolarik jan-kolarik commented Nov 11, 2022

There are some uninteresting progress events with zero values coming at the beginning of the metadata download which causes the percent widget to show 100% before the actual downloading starts.

As there is already implemented showing the ???%, I assume this was the original intention, so I fixed the incorrectly initialized members in the ProgressBar class.

This is a follow-up of #130

@jrohel jrohel self-assigned this Nov 11, 2022
@jan-kolarik jan-kolarik force-pushed the jkolarik/fix-progress-at-start branch from adc0225 to 7d28355 Compare November 14, 2022 09:52
@jrohel
Copy link
Contributor

jrohel commented Nov 14, 2022

Thanks. I know, it's a little PR. But can you please split it into two commits?

  • The first commit then fixes the progress_bar implementation of the "progress_bar.hpp" and "progress_bar/cpp" files.
  • The second commit will modify the "context.cpp" file of the dnf5 application.

Setup ticks and percent done values to -1 after object is created, because zero is considered as progress done in some situations.
There are some uninteresting progress events with zero values coming at the beginning of the metadata download which causes the percent widget to show 100% before the actual downloading starts.
@jan-kolarik jan-kolarik force-pushed the jkolarik/fix-progress-at-start branch from 7d28355 to c0ef82e Compare November 14, 2022 11:51
@jrohel jrohel merged commit 4784e90 into main Nov 14, 2022
@jrohel jrohel deleted the jkolarik/fix-progress-at-start branch November 14, 2022 11:54
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

Successfully merging this pull request may close these issues.

2 participants