Skip to main content

Quick and easy logging initialization

Project description

Logfast

Purpose

Just a simple python package which does logging initialization in a certain way.

17|12|19|00:18:58|+0100  14474:MainThread  INFO       |__init__.py.21  |   This is an example
17|12|19|00:18:58|+0100  14474:MainThread  WARNING    |__init__.py.22  |   Another one

As one can see it provides the filename where the log has been created, the Process ID, the Thread Name, and the full time (including timezone). This is a package I created for my own benefit, as i found myself tired of always doing the same logging initalization.

Now i can just pip install logfast wherever i am.

Most likely you will want to a have different logging format than me(so this package might be of no use to you). But if you want the same format feel free to use it.

Installation

pip install logfast

Usage Guide

Make sure this is the first module you import in your application. This makes sure no other call is made first to logging. Otherwise other modules/libraries might overwrite the logging settings. This allows you to have multiple application entrypoints but have the same logging configuration.

import logfast

logger = logfast.getLogger()


logger.info("This is an example")
logger.warning("Another one")

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

logfast-0.5.0.tar.gz (3.8 kB view details)

Uploaded Source

Built Distribution

logfast-0.5.0-py3-none-any.whl (4.2 kB view details)

Uploaded Python 3

File details

Details for the file logfast-0.5.0.tar.gz.

File metadata

  • Download URL: logfast-0.5.0.tar.gz
  • Upload date:
  • Size: 3.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.11.1

File hashes

Hashes for logfast-0.5.0.tar.gz
Algorithm Hash digest
SHA256 708e222514376aaa161bae945695e2935d1d1649df73f9b382d3eb56eb93beed
MD5 5cbbef7bd087d01912a8c380f3d99d75
BLAKE2b-256 afcc78b7c93d5afd6c43ea012e8e02df8f0ea25a09e43d8218d2b06209fe2a2b

See more details on using hashes here.

File details

Details for the file logfast-0.5.0-py3-none-any.whl.

File metadata

  • Download URL: logfast-0.5.0-py3-none-any.whl
  • Upload date:
  • Size: 4.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.11.1

File hashes

Hashes for logfast-0.5.0-py3-none-any.whl
Algorithm Hash digest
SHA256 0229992764dea44df4cbab7b600236beb77da558688956db7374b3547231d2b7
MD5 c4eb39e2f6a07f075195e0402c7ce0c8
BLAKE2b-256 9e3d6445a174c4c97068da309dd4baca9948ce86ba745dcacee6c61dc47a869f

See more details on using hashes here.

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