Skip to main content

An application log system similar to Android Logcat for Python

Project description

PyLogcat

PyLogcat is an application log system similar to Android Logcat for Python.

PyLogcat currently supports the following log levels.

  • Error : Critical messages which can cause application malfunction
  • Warning : Priority messages which indicate the potential problem in application
  • Information : Proirity messages which help users tracing application execution
  • Verbose : Debug messages which help developers debugging application under development

How To

Install package

pip install pylogcat

Import modules

from pylogcat import Log, Level

Log module privodes main functions for application log.

Level enumerates supported log levels as v, i, w, and e for verbose, informatin, warning, and error messages.

Setup log level

Log level is set as verbose which means all messages will be shown. Users can set log level as error, warning, information, or verbose as required. For example, users can set log level as information by adding the following line of code

Log.level = Level.i

Create log message

Verbose log message

Log messages will be shown only if log level is set as v.

Log.v(tag, message)

Information log message

Log messages will be shown only if log level is set as v or i.

Log.i(tag, message)

Warning log message

Log messages will be shown only if log level is set as v, i, or w.

Log.w(tag, message)

Error log message

Log messages will be shown no matter what log level is set.

Log.e(tag, message)

Limitations

PyLogcat can only print log messages on console now.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Files for pylogcat, version 0.0.3
Filename, size File type Python version Upload date Hashes
Filename, size pylogcat-0.0.3-py3-none-any.whl (6.7 kB) File type Wheel Python version py3 Upload date Hashes View
Filename, size pylogcat-0.0.3.tar.gz (2.2 kB) File type Source Python version None Upload date Hashes View

Supported by

AWS AWS Cloud computing Datadog Datadog Monitoring DigiCert DigiCert EV certificate Facebook / Instagram Facebook / Instagram PSF Sponsor Fastly Fastly CDN Google Google Object Storage and Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Salesforce Salesforce PSF Sponsor Sentry Sentry Error logging StatusPage StatusPage Status page