rsalmei / alive-progress

A new kind of Progress Bar, with real-time throughput, ETA, and very cool animations!
MIT License
5.53k stars 206 forks source link

Unknown mode always end with a warning `(!)` #211

Closed divulgacheur closed 1 year ago

divulgacheur commented 1 year ago

According to README gif alive_bar in unknown mode must end without warning character (!) :thinking:

Example :

with alive_bar(total=0, title='Searching', stats=False, disable=opts.quiet, monitor="Page {count}") as progress_bar:
    while ... is False:
        progress_bar()
    progress_bar.title = 'Search has finished'

Output (Python 3.10)

Search has finished |████████████████████████████████████████| (!) Page 1 in 4.0s 

Expected output:

Search has finished |████████████████████████████████████████| Page 1 in 4.0s 
TheTechRobo commented 1 year ago

Why is your total set to 0?

divulgacheur commented 1 year ago

I thought it was the mandatory value in order to run in unknown mode, but the result is the same without total=0.

TheTechRobo commented 1 year ago

I'm not sure then. @rsalmei will probably be able to figure it out, though.

TheodoreHua commented 1 year ago

Can confirm that this occurs on the latest version (v2.4.1) with or without a value passed into total. Seems to always have a warning character even in unknown mode. From a quick test, it doesn't occur in version v2.2.0 but does occur in all versions above. Maybe I forgot to port something when updating from 2.1.0 -> latest but it does seem to match the documentation.

rsalmei commented 1 year ago

Humm, I'll take a look as soon as I can, thank you all for reporting it.

rsalmei commented 1 year ago

Hi, it is really a small bug, should be fixed in the next version 👍