Skip to main content

A simple logging configuration module

Project description

Sane Logger

This module provides a simple logging configuration with a named logger for Python applications.

The settings are %(asctime)s [%(threadName)-12.12s] [%(levelname)-5.5s] %(message)s.

Installation

You can install the package using pip:

pip install a_sane_logger

Usage

Simply import the module in your code and use the logger:

import a_sane_logger as sn

logger = sn.sane_logger

logger.info("This is an info message.")
logger.error("This is an error message.")

The logs should look like:

2024-10-09 18:57:24,520 [MainThread  ] [INFO ]  This is an info message.
2024-10-09 18:57:26,204 [MainThread  ] [ERROR]  This is an error message.

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

a_sane_logger-0.2.tar.gz (1.5 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

a_sane_logger-0.2-py3-none-any.whl (1.5 kB view details)

Uploaded Python 3

File details

Details for the file a_sane_logger-0.2.tar.gz.

File metadata

  • Download URL: a_sane_logger-0.2.tar.gz
  • Upload date:
  • Size: 1.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.12.5

File hashes

Hashes for a_sane_logger-0.2.tar.gz
Algorithm Hash digest
SHA256 de8d5506d18334d823484709cac9a2b3229a0fb12de905b7ac443e80293b8b3f
MD5 6e6a0dbc1d1c6d0e5f0a727cc26194b0
BLAKE2b-256 94f6d090d1f1a003a40401e2ff66fd5b3ad272eca3d05017e5f468c0e36f3f10

See more details on using hashes here.

File details

Details for the file a_sane_logger-0.2-py3-none-any.whl.

File metadata

  • Download URL: a_sane_logger-0.2-py3-none-any.whl
  • Upload date:
  • Size: 1.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.12.5

File hashes

Hashes for a_sane_logger-0.2-py3-none-any.whl
Algorithm Hash digest
SHA256 8ecc73016328bffef972e451c53cdef88aa4404ca31da2b5650875699d7ca5aa
MD5 b81444b65f8469d92806b375c578648b
BLAKE2b-256 b188eea376a856223442317cce1cdf5232d77add0309ab92d12f5d1b807c7c3c

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page