Skip to main content

A Python Library For All Python Pet Peeves

Project description

PyPI GitHub Workflow Status CodeQL GitHub Workflow Status Upload Python Package PyPI - Python Version GitHub

pypeeve

PyPeeve is a python library for python pet peeves! As a developer, you know how time-consuming and tedious it can be to write the same boilerplate code over and over again. The aim of this library is to provide a tool that helps developers to reduce their unnecessary effort in writing boilerplate codes repeatedly in every project, allowing you to focus on what really matters - solving problems and building new features.

Installation

To install the latest version, run-

pip install pypeeve

What PyPeeve Offers

There are the list of things pypeeve offers so far:

Logger

Pypeeve provides a set of pre-configured loggers. The simplest and quickest way to use pypeeve logger and logger decorators is to import a pre-configured logger that suit your need.

from pypeeve.logger import logger

@logger.default
@logger.perf
def do_something():
    logger.info("Info logs")
    logger.error("Error logs")

Output-

[2023-03-27 02:28:47,680] - [DEBUG] - Entering do_something()
[2023-03-27 02:28:47,681] - [INFO] - Info logs
[2023-03-27 02:28:47,681] - [ERROR] - Error logs
[2023-03-27 02:28:47,682] - [DEBUG] - do_something() starting time: 91411.408944
[2023-03-27 02:28:47,682] - [DEBUG] - do_something() ending time: 91411.409873
[2023-03-27 02:28:47,683] - [INFO] - Total time taken to finish do_something(): 0.000929 second(s)
[2023-03-27 02:28:47,684] - [DEBUG] - Exiting do_something()

The detailed documentation about the pypeeve loggers can be found in logger readme.

License

Pypeeve is distributed under MIT License. License details of all the third party tools used in pypeeve can be found in Third Party Licenses.

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

pypeeve-1.0.1.tar.gz (6.8 kB view hashes)

Uploaded Source

Built Distribution

pypeeve-1.0.1-py3-none-any.whl (6.4 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