A context manager to deal with logging level as context manager.
Project description
Logging as a context manager.
Visually inspired by how Credo looks like, I always find difficult to communicate with user in command line interface. So this is a logging/printing system which is more block based than line base, and with color also.
The following will show a nice formatted message :
with Message('Hello there') as log:
log('This is a Logging message context manager')
log('it support nesting and will render in a User friendly way')
log('I need to fix multi \nline \nstring')
You can nest these:
with Message('Hello there') as log:
log('This is a Logging message context manager')
log('it support nesting and will render in a User friendly way')
log('I need to fix multi \nline \nstring')
with Warning('Nested it does support') as log1:
log1('like Yoda speach order ')
log1('of words are')
with Critical('Come to the dark side') as log2:
log2('we have cookies')
with OK("Paternity test") as log3:
log3('I am your father')
To get nested messages:
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 Distributions
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file withlog-0.0.3-py2.py3-none-any.whl.
File metadata
- Download URL: withlog-0.0.3-py2.py3-none-any.whl
- Upload date:
- Size: 10.5 kB
- Tags: Python 2, Python 3
- Uploaded using Trusted Publishing? No
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
3800d684ce1dca5a3ee895cbaf3d405238b8611755b037873e28b5d62ba7d8ed
|
|
| MD5 |
8fa4343feb7b9f83cccf44881051436b
|
|
| BLAKE2b-256 |
d7c819bccf635e7a8e2dbeb9d032120c40c2ef91bcc7a16588d67164fc015f74
|