Skip to main content

No project description provided

Project description

indentalog

An easy-to-use progress bar decorator for Python functions and loops.

Getting Started

indentalog will be available on PyPI once it reaches a stable version. For now, you can install it from the source code.

git clone git@github.com:bastienlc/indentalog.git
cd indentalog
poetry install

indentalog has the simplest API possible. Just import the ilog object and use it either as a decorator, as an iterator wrapper or as a context manager.

from indentalog import ilog

@ilog()
def my_first_function():
    # Your code here
    pass

def my_second_function():
    for i in ilog(range(10)):
        # Your code here
        pass

my_first_function()
my_second_function()

GIF for the first example.

The main advantage of indentalog is that it keeps track of the call stack, which allows displaying the progress of nested functions or loops.

from indentalog import ilog

@ilog()
def my_inner_function():
    # Your code here
    pass

def my_main_function():
    for i in ilog(range(3), name="Main function"):
        # Your code here
        my_inner_function()
        pass

my_main_function()

GIF for the first example.

Future features

  • Passing data to the endpoints
  • Support for custom styles or themes

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

indentalog-0.1.1.tar.gz (5.3 kB view hashes)

Uploaded Source

Built Distribution

indentalog-0.1.1-py3-none-any.whl (7.7 kB view hashes)

Uploaded Python 3

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