Skip to main content

High level logging client builtin support for colored terminal output

Project description

Log3

image image codecov Build Status GitHub

Log3 makes it easier to log to python. Log3 comes with a strong default logging configuration system so you don't configure them yourself.

If you're working with the console a lot, log will display a colored output.

Installation

pip install log3

Usage

To start logging it is as simple as importing the log object and issuing the logging commands:

from log3 import log

log.info("Hello world")
log.debug("This is a debug message")
log.warning("This is a warning")
log.error("This is an error")

Log to file

The log_to_file method will allow you to add a file handler to yor logging configuration

log.log_to_file('file')
log.info('logged to file')

Disable logging

You can quickly disable logging rather than hardcoding it into your logging configuration file.

log.disable_logging()

To enable logging again it is also that simple:

log.enable_logging()

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

log3-0.1.5.tar.gz (3.0 kB view hashes)

Uploaded Source

Built Distribution

log3-0.1.5-py3-none-any.whl (4.6 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