Skip to main content

A simple Python logging utility for colorful terminal output

Project description

Log Candy

Log Candy is a simple and colorful logging utility designed to make your debug messages more delightful and informative. It provides easy-to-use functions for logging messages with different levels of importance, using vibrant colors for better distinction.

Features

  • 🌈 Color-Coded Logs: Debug, Info, Warning, Error, and Result messages are each represented with a unique color for easy identification.

  • 📝 Readable Formatting: Automatically formats multiline messages for improved readability.

  • 🛠️ Customizable Use: Straightforward integration to be used anywhere in your Python projects.

Installation

You can install Log Candy via pip:

pip install log-candy

Requirements

  • Python 3 version or higher is required.

Dependencies

The package also carries the following dependencies (requirements.txt) for better use:

tqdm==4.66.4

Usage

Import Log Candy and start logging colorful messages in your project:

from log_candy import log_debug, log_info, log_warning, log_error, log_result

# Classic logging
log_debug("This is a debug message.")
log_info("This is an info message.")
log_warning("This is a warning message.")
log_error("This is an error message.")
log_result("This is a result message.")

# Multiline logging
log_debug("This is a debug message.\nThis is a multiline debug message.")
log_info("This is an info message.\nThis is a multiline info message.")
log_warning("This is a warning message.\nThis is a multiline warning message.")
log_error("This is an error message.\nThis is a multiline error message.")
log_result("This is a result message.\nThis is a multiline result message.")

Why Use Log Candy?

  • 🛠 Ease of Use: No setup required, just import and start logging.

  • 🌟 Improved Clarity: Quickly identify different types of logs by their color-coded format.

  • 💡 Multiline Support: Automatically indents subsequent lines to keep your logs neat.

Contributing

Contributions are welcome! If you have suggestions for improvements, please feel free to open an issue or create a pull request.

Steps to Contribute

  1. Fork the repository.

  2. Create a new branch (git checkout -b feature/amazing-feature).

  3. Commit your changes (git commit -m 'Add amazing feature').

  4. Push to the branch (git push origin feature/amazing-feature).

  5. Open a Pull Request.

Acknowledgements

Special thanks to anyone who finds this project useful and helps make it better!

Enjoy logging with Log Candy 🍭!

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

log-candy-0.1.2.tar.gz (3.6 kB view details)

Uploaded Source

Built Distribution

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

log_candy-0.1.2-py3-none-any.whl (4.0 kB view details)

Uploaded Python 3

File details

Details for the file log-candy-0.1.2.tar.gz.

File metadata

  • Download URL: log-candy-0.1.2.tar.gz
  • Upload date:
  • Size: 3.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.0.1 CPython/3.10.13

File hashes

Hashes for log-candy-0.1.2.tar.gz
Algorithm Hash digest
SHA256 05703ed8064572c8c1a747c82ef88dcbb4ed032796cdcfa8701a47fffa56b45d
MD5 10f651b37dc0d3d4080e4bc263a6f8ee
BLAKE2b-256 433c2df08bcd7a63c47da25d7075808fea2ab873258a4ff2363c2172f2b605bb

See more details on using hashes here.

File details

Details for the file log_candy-0.1.2-py3-none-any.whl.

File metadata

  • Download URL: log_candy-0.1.2-py3-none-any.whl
  • Upload date:
  • Size: 4.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.0.1 CPython/3.10.13

File hashes

Hashes for log_candy-0.1.2-py3-none-any.whl
Algorithm Hash digest
SHA256 9963d824e0090595655dc794f20a6cd3ef8cd09b6866b7aa9da4881ddd9653a1
MD5 1acfbfe9e58051bc3b4d71c6e7c58839
BLAKE2b-256 55fad13a5d7d8bfb1a60d912837dcaa94d696420859cfae400860c0cb16af569

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