Skip to main content

A project started to fix a problem I was having with the default python logging library

Project description

Char's Better Logs

A project started to fix a problem I was having with the default python logging library

USAGE

Simply install it with pip install chars-betterlogs and add it to your code with:

from chars_betterlogs.logs import Logging

then make a variable:

#                         The Filename         String to add before the log        Whether to print the log (Defaults to True)
logger:Logging = Logging('filename.log', 'This gets added before the log starts!', False)

Tada you now have a callable logger!

Example Script

from chars_betterlogs.logs import Logging
from datetime import datetime

logger:Logging = Logging('log_' + str(datetime.today().strftime('%d_%m_%Y-%H_%M_%S')) + '.log')

logging.log_info('yipee!')
logging.close() # Don't forget to end the log file before the script ends!

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

chars_betterlogs-3.3.0.dev2.tar.gz (19.3 kB view details)

Uploaded Source

Built Distribution

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

chars_betterlogs-3.3.0.dev2-py3-none-any.whl (20.6 kB view details)

Uploaded Python 3

File details

Details for the file chars_betterlogs-3.3.0.dev2.tar.gz.

File metadata

  • Download URL: chars_betterlogs-3.3.0.dev2.tar.gz
  • Upload date:
  • Size: 19.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for chars_betterlogs-3.3.0.dev2.tar.gz
Algorithm Hash digest
SHA256 a3fffb0e64e72d54ecaff99e2306b41af91fae3cf3f5949b5718ea009b8aa830
MD5 12124cccb2b1acef0a0e05f8a3ec9b9a
BLAKE2b-256 f62679a669512358f8947622ba6513c4ad7717ee98019848a98a990abd237dab

See more details on using hashes here.

File details

Details for the file chars_betterlogs-3.3.0.dev2-py3-none-any.whl.

File metadata

File hashes

Hashes for chars_betterlogs-3.3.0.dev2-py3-none-any.whl
Algorithm Hash digest
SHA256 2adc698b8a0133922fd29584725c43af500ef4708b6318f0fc4ba0c778c02921
MD5 4e922881a7b922c1b5ba4881eee8677a
BLAKE2b-256 e1f25f309d733591641c79cabb1940f5e420a64f4164728c406d6fc0d6644be6

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