indentalog
An easy-to-use progress logger for Python. indentalog allows you to display the progress of your functions and loops in a clean and readable way, by keeping track of the call stack. It uses rich under the hood to provide a beautiful and customizable output.
Getting Started
indentalog is available on PyPI. It is still in early development, so you may encounter some bugs. If you do, please open an issue on github.
pip install indentalog
indentalog aims to make logging your script's progress as easy as 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()
indentalog keeps track of the call stack, which allows displaying the progress of nested functions or loops without getting lost in the output.
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()
Contributing
Contributions are welcome! If you have any idea or suggestion, please open an issue on github. This project is still in early development, so there is a lot of room for improvement.
Installation
git clone git@github.com:bastienlc/indentalog.git
cd indentalog
make install
License
This project is licensed under the MIT License - see the LICENSE file for details.
Metadata
Release files for indentalog 0.1.3
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| indentalog-0.1.3.tar.gz | 5.5 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| indentalog-0.1.3-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 13.4 kB
Release files / indentalog-0.1.3.tar.gz
| Download URL | indentalog-0.1.3.tar.gz |
|---|---|
| Size | 5.5 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
5773b74e91343fb5832badfa71e69d788a321d7110ccb47f3914a75ea8d3e918
|
|
BLAKE2b-256 checksum How to use checksums |
3324f6785ca4d23d7ecbbb068cd97b38aaacb7f0fc70ad1b7a38935870e24515
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/5.1.1 CPython/3.12.7
|
Release files / indentalog-0.1.3-py3-none-any.whl
| Download URL | indentalog-0.1.3-py3-none-any.whl |
|---|---|
| Size | 7.9 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
e5d011776866e8d90888ff858cafc218397a181a2289720205ee26a03800c649
|
|
BLAKE2b-256 checksum How to use checksums |
b5a20889d511d17d733051b1940407f28f04a238341ee0de18a2e4e189aadb8a
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/5.1.1 CPython/3.12.7
|