Skip to content

Conversation

Ahsoka
Copy link
Contributor

@Ahsoka Ahsoka commented Aug 11, 2020

This pull request fixes #689. Additionally it also adds a progress bar when using the initial parameter where previously there was no progress bar at all. See .gifs below for reference.

Before this PR ⬇
Anaconda-Prompt-2020-08-10-20-32-50_Trim

After this PR ⬇
Anaconda-Prompt-2020-08-10-20-42-45_Trim

Code used in both of the .gifs above

import tqdm
import time
for _ in tqdm.trange(10, initial=90):
    time.sleep(0.1)

I believe it also fixes #215.
(Github AI please link #215 XD)

@Ahsoka Ahsoka requested a review from casperdcl as a code owner August 11, 2020 03:49
@codecov-commenter
Copy link

codecov-commenter commented Aug 11, 2020

Codecov Report

Merging #1021 into devel will increase coverage by 0.00%.
The diff coverage is 100.00%.

@@           Coverage Diff           @@
##            devel    #1021   +/-   ##
=======================================
  Coverage   87.06%   87.07%           
=======================================
  Files          22       22           
  Lines        1353     1354    +1     
  Branches      229      229           
=======================================
+ Hits         1178     1179    +1     
  Misses        151      151           
  Partials       24       24           

@casperdcl
Copy link
Member

Ah thanks for this; was intending on fixing it in the next release

@casperdcl casperdcl added c1-quick 🕐 Complexity low p2-bug-warning ⚠ Visual output bad to-merge ↰ Imminent labels Aug 11, 2020
@casperdcl casperdcl self-assigned this Aug 11, 2020
@casperdcl casperdcl changed the title Fixed #689 fix total ETA when using initial Aug 11, 2020
@casperdcl casperdcl changed the base branch from master to devel August 11, 2020 10:03
- also allow using `initial` without explicit `total`
- fixes tqdm#689
@casperdcl casperdcl mentioned this pull request Sep 7, 2020
@casperdcl casperdcl merged commit 2689c9d into tqdm:devel Sep 7, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
c1-quick 🕐 Complexity low p2-bug-warning ⚠ Visual output bad to-merge ↰ Imminent
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Incorrect number of iterations per second
3 participants