Skip to main content

dailylog

Build Status codecov Python Version wemake-python-styleguide

Overview

I have many scripts run by cron and report errors via cron's email. This is great until one of the scripts that runs frequently starts failing. Rather than waking to a full mailbox, using this tool will throttled specific errors to a log and only show the error every 24 hours by default. The time can be adjusted by passing a parameter.

Installation

Check out this repo and cd into the project directory and run:

pip install dailylog1

Usage

dailylog --help
Usage: dailylog [OPTIONS] COMMAND [ARGS]...

  Entry point for click script.

Options:
  -C, --cache TEXT        specify alternate cache file (default ~/.cache/dailylog.json)
  -c, --config TEXT       specify alternate config file (default ~/.config/dailylog.yaml)
  -d, --debug             increment debug level
  -t, --test / --no-test  specify test mode
  -v, --verbose           increment verbosity level
  -V, --version           show version and exit
  -h, --help              Show this message and exit.

Commands:
  log              Log an error.
  set-default-log  Set a new default log.
dailylog log --help
Usage: dailylog log [OPTIONS]

  Log a message.

Options:
  -k TEXT     Specify key  [required]
  -m TEXT     Specify message  [required]
  -s INTEGER  Specify seconds to suppress (default 86400 [one day])
  -l INTEGER  Specify one of logging levels (default: logging.ERROR)
  -f TEXT     Specify alternate log file
  -h, --help  Show this message and exit.
dailylog set-default-log --help
Usage: dailylog set-default-log [OPTIONS] LOG_FN

  Set a new default log.

Options:
  -h, --help  Show this message and exit.

Documentation

License

MIT

Metadata

Release files for dailylog1 0.3.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for dailylog1 0.3.0
File Size Uploaded
dailylog1-0.3.0.tar.gz 8.2 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for dailylog1 0.3.0
File Interpreter ABI Platform
dailylog1-0.3.0-py3-none-any.whl Python 3 none any Details

Total release size: 17.7 kB

Release files / dailylog1-0.3.0.tar.gz

Download URL dailylog1-0.3.0.tar.gz
Size 8.2 kB
Tags Source
SHA-256 checksum
How to use checksums
cc165c4480d1034d3fff926649be24da56a246b6fe364d10f47f5cb1a9261f0b
BLAKE2b-256 checksum
How to use checksums
572459a451ce5044fbd2a288e49405c5c7de20bbbd87fe29034be22a72fd021d
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/1.8.5 CPython/3.13.2 Linux/6.12.13-200.fc41.x86_64

Release files / dailylog1-0.3.0-py3-none-any.whl

Download URL dailylog1-0.3.0-py3-none-any.whl
Size 9.5 kB
Tags Python 3
SHA-256 checksum
How to use checksums
daf1ef55eda7c0c8c24c0b29c1ed91e3223c9d896ca8fbc98183be257b4b9eba
BLAKE2b-256 checksum
How to use checksums
7b57c5267dc27e452bdbec4385372eeb2785a8d8cdeb309e70e58298f45832e6
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/1.8.5 CPython/3.13.2 Linux/6.12.13-200.fc41.x86_64

Release history Release notifications | RSS feed

This release

0.3.0 This release

2 release files

0.2.3

2 release files

0.2.2

2 release files

0.2.1

2 release files

0.2.0

2 release files

0.1.8

2 release files

0.1.7

2 release files

0.1.5

2 release files

0.1.4

2 release files

0.1.3

2 release files

0.1.2

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page