Wrap standard-library logging to support TQDM progress-bars.
Project description
TQDM logging wrapper
Wrap standard-library logging to support TQDM progress-bars.
Installation
pip install tqdm-logging-wrapper
Usage
import logging
import tqdm
import tqdm_logging_wrapper
logger = logging.getLogger(__name__)
logging.basicConfig(level=logging.INFO)
items = [1, 2, 3]
items_iter = tqdm.tqdm(items)
logger.info(f"Items: {items}")
with tqdm_logging_wrapper.wrap_logging_for_tqdm(items_iter), items_iter:
for item in items_iter:
logger.info(f"Item: {item}")
logger.info(f"Items: {items}")
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Close
Hashes for tqdm-logging-wrapper-1.0.1.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | 072d00d3fc915af1191e65af8840039cefa623e17c119dba485206dfa41dd440 |
|
MD5 | a186030275befcd20a0a26638c1ff6a4 |
|
BLAKE2b-256 | 06a1debf3b48ee1aacc19f160592fca3cbd4b4ca5efc86f9f21e0e1d4be555d2 |
Close
Hashes for tqdm_logging_wrapper-1.0.1-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | aa77a881ce49d56a6f3530bd64d19204b32163430983fe33aa745b18263f6222 |
|
MD5 | 1cdd9f7ab3c108f7257742b5f596a8d0 |
|
BLAKE2b-256 | 0514c34693db4831832e1a4ac1d8ff41971b0894ce70d9ba5baa035500ff782b |