Skip to content

divulge

Opinionated console messaging for Python — coloured, prefixed info, success, warning, error, and system lines.

Install the lupaxa-divulge package and import the lupaxa.divulge namespace:

pip install lupaxa-divulge
import lupaxa.divulge as divulge

divulge.info("Server starting")
divulge.success("Operation completed")
divulge.warning("Disk usage high")
divulge.error("Connection failed")
divulge.system("Starting backup job")

divulge is a library only. There is no console script and no python -m entry point.

Levels

Level Stream Default prefix Default colour
info stdout [ Info ] light_cyan
success stdout [ Success ] light_green
warning stderr [ Warning ] light_yellow
error stderr [ Error ] light_red
system stdout [ System ] dark_grey

Colours come from termcolor. Prefixes and colours can be turned off for the process, or overridden on a single call. Bold is off by default; pass use_bold=True to enable it.

Next steps