Skip to main content

A Python library for displaying progress indicators and progress bars in the console with customizable messages and colors.

Project description

Progress Indicator Library

A Python library providing two classes for displaying progress indicators in the console: ProgressIndicator and ProgressBar. These classes help visualize ongoing tasks by displaying an animated spinner or a progress bar, respectively.

Publish PyPI version

Python Versions

Installation

To install the library, you can use pip:

pip install progress_basic

Usage

ProgressIndicator

The ProgressIndicator class displays an animated spinner with a customizable message and color.

Example

from progress_basic.format.color_text import AnsiColors
from progress_indicator import ProgressIndicator

with ProgressIndicator("Processing", color=AnsiColors.OKBLUE) as pi:
    # Simulate a long-running task
    time.sleep(5)

ProgressBar

The ProgressBar class displays a progress bar that updates as tasks progress, with customizable total steps, message, interval, bar length, and color.

Example

from progress_basic.format.color_text import AnsiColors
from progress_bar import ProgressBar

total_steps = 100

with ProgressBar(total_steps, message="Loading", color=AnsiColors.OKBLUE) as pb:
    for i in range(total_steps):
        pb.update(i + 1)
        time.sleep(0.1)  # Simulate work

Classes

ProgressIndicator

A class for displaying an animated spinner with a customizable message and color.

ProgressBar

A class for displaying a progress bar that updates as tasks progress, with customizable total steps, message, interval, bar length, and color.

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

progress_basic-0.3.tar.gz (4.3 kB view details)

Uploaded Source

Built Distribution

progress_basic-0.3-py3-none-any.whl (4.4 kB view details)

Uploaded Python 3

File details

Details for the file progress_basic-0.3.tar.gz.

File metadata

  • Download URL: progress_basic-0.3.tar.gz
  • Upload date:
  • Size: 4.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.12.4

File hashes

Hashes for progress_basic-0.3.tar.gz
Algorithm Hash digest
SHA256 90b5a6969c4301c4461b2f9922d776dc7babd441c4f6595da75fddf4957f0368
MD5 5f0e5900dba9d98f0e3be591fba27986
BLAKE2b-256 f3d09fc5f2fdbf998bcea848841e09cba7dfc818951b89b99c19fabc19e72127

See more details on using hashes here.

File details

Details for the file progress_basic-0.3-py3-none-any.whl.

File metadata

File hashes

Hashes for progress_basic-0.3-py3-none-any.whl
Algorithm Hash digest
SHA256 874d35eb3e976965136921029c061b347869f18be6c09f693c42a3f11f05d8dc
MD5 660d7da2ab719019d944aa13a2aebb1b
BLAKE2b-256 8a148e2c0dab757163f3ca664501f7cb42c9ae4a819b586b7fcd94ae04600d6e

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