Skip to main content

Customize and create a progress bar string.

Project description

Better-Progress

A progress bar that actually doesn't make assumptions.

This package is heavily inspired by the progress package. However, unlike progress, this package handles progress bars in a sane and user-friendly way.

Basic usage

Progress bars

from better_progress import Bar

progress_bar = Bar.Bar(max_value)
print(progress_bar)

Fillers

from better_progress import Filler

filler = Filler.Filler(max_value)
print(filler)

Spinners

from better_progress import Spinner

#...

spinner = Spinner.Spinner()
while working:
    #...
    spinner.next()
    print(spinner)

Comparisons between progress and better-progress

  • Viewing the progress bar
    • Progress: the default behavior is to print out the progress bar to stdout upon iteration. There is no other way to get a string representation of the progress bar.
    • Better-progress: nothing is printed out to stdout. Instead, the user can get a string of the progress bar by simply getting the string representation of any of the classes provided in the library.
  • Documentation
    • Progress: No docstrings, documentation in the repository is severely lacking. Many properties are expected to be in kwargs, making it incredibly difficult to read through the source by hand.
    • Better-progress: Docstrings for every module, class, and function. Nothing should come as a surprise to the user. No reliance on kwargs, except where it makes sense. Type hints are also provided for every parameter and function return.
  • Usage in your code
    • Progress: Because it automatically prints to stdout, the user needs to work around the library, potentially changing the structure they already have in place.
    • Better-progress: Because this library only tracks state and gives a string upon request, the library can work around the user. The user doesn't need to make any big changes to get the library to work for them.
  • Other features
    • Progress has many other features aside from producing a progress bar. It tracks the average time between increments, the elapsed time since starting, and the ETA until completion.
    • Better-progress does not have these features. The philosophy is that this is a package that lets the user create a pretty progress bar, nothing more. If the user wants any of these features, they would be simple enough to include alongside where they use the progress bar.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

better-progress-1.0.3.post1.tar.gz (11.5 kB view details)

Uploaded Source

Built Distribution

better_progress-1.0.3.post1-py3-none-any.whl (13.9 kB view details)

Uploaded Python 3

File details

Details for the file better-progress-1.0.3.post1.tar.gz.

File metadata

  • Download URL: better-progress-1.0.3.post1.tar.gz
  • Upload date:
  • Size: 11.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.5.0.1 requests/2.24.0 setuptools/49.6.0 requests-toolbelt/0.9.1 tqdm/4.50.0 CPython/3.8.5

File hashes

Hashes for better-progress-1.0.3.post1.tar.gz
Algorithm Hash digest
SHA256 abcb701ed2c1bd5a60c354dbe6f2a12d86b4e43eb4a2ba6d397cda1a6ebfc9dc
MD5 452fbd0dbcd1f0cf8f6d75699a117a46
BLAKE2b-256 40519f2bde4a4e2c386f10da781479b7863531046e0706ac3436809ecb5c03d5

See more details on using hashes here.

File details

Details for the file better_progress-1.0.3.post1-py3-none-any.whl.

File metadata

  • Download URL: better_progress-1.0.3.post1-py3-none-any.whl
  • Upload date:
  • Size: 13.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.5.0.1 requests/2.24.0 setuptools/49.6.0 requests-toolbelt/0.9.1 tqdm/4.50.0 CPython/3.8.5

File hashes

Hashes for better_progress-1.0.3.post1-py3-none-any.whl
Algorithm Hash digest
SHA256 fe6c72c8456893807abd796df2d6992e999137403542882a565637c7edbed51f
MD5 9b1728357da5f3ec6d238b4696b49abd
BLAKE2b-256 f1a59b67b96c4fc931c3182ac0cd69dabc4af484497db061b75b3e016606e31a

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page