Skip to main content

A log package that works with MongoDB.

Project description

The idea behind this package is possibility to you use some client or something like the Metabase for collect and analyse logs of your application.

Its need two environments variables:

  • MONGO_DB
  • MONGO_URL

Its works with three collections:

  • error
  • info
  • critical

Sample:

from mongo_system_log import *
log = LogThis(get_module_name())
log.info('error message', payload='payload', result='result')
log.error('error message', payload='payload', result='result')
log.critical('error message', payload='payload', result='result')

get_module_name()

  • This function gets module and file name that called it. Must be called on instantiate the LogThis class.
    The arguments payload and result has default value None.

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

mongo-system-log-0.1.0.tar.gz (2.9 kB view hashes)

Uploaded Source

Built Distribution

mongo_system_log-0.1.0-py3-none-any.whl (15.9 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