Skip to main content

A generic logging package for python projects

Project description

# aklogger

Keep track of all the events happening in your project: A generic logging package for python projects.

## [Features]

- Logging to console
- Logging to file
- Push logs to slack

## Installation

```
$ pip install aklogger
```

## Usage

Following script will log messages to slack, file and console:

```python
import aklogger

token = SLACK_API_KEY
channel = CHANNEL_NAME

logger = aklogger.AKLogger('test', level='DEBUG')
f_handler = aklogger.handlers.FileHandler('test.log')
c_handler = aklogger.handlers.StreamHandler()
s_handler = aklogger.handlers.SlackerLogHandler(token, channel)

logger.add_handler(f_handler)
logger.add_handler(c_handler)
logger.add_handler(s_handler)

logger.error('This is title', 'This is description')
```

See [python logging docs](https://docs.python.org/3/library/logging.html) for more uses.


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

aklogger-0.0.2a1.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.

aklogger-0.0.2a1-py2.py3-none-any.whl (5.1 kB view details)

Uploaded Python 2Python 3

File details

Details for the file aklogger-0.0.2a1.tar.gz.

File metadata

  • Download URL: aklogger-0.0.2a1.tar.gz
  • Upload date:
  • Size: 3.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.21.0 setuptools/40.8.0 requests-toolbelt/0.9.1 tqdm/4.31.1 CPython/3.6.5

File hashes

Hashes for aklogger-0.0.2a1.tar.gz
Algorithm Hash digest
SHA256 cf40c7c021f5fbfd173dffa1356451c6b2cf89fa24fb431594848b7c084f5da9
MD5 66b4bf1095fa536f2a0d0df2e0828023
BLAKE2b-256 4d61efecb3eb13616eff36f20712dc8641d4f3dd57826321c6680c298f1d5621

See more details on using hashes here.

File details

Details for the file aklogger-0.0.2a1-py2.py3-none-any.whl.

File metadata

  • Download URL: aklogger-0.0.2a1-py2.py3-none-any.whl
  • Upload date:
  • Size: 5.1 kB
  • Tags: Python 2, Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.21.0 setuptools/40.8.0 requests-toolbelt/0.9.1 tqdm/4.31.1 CPython/3.6.5

File hashes

Hashes for aklogger-0.0.2a1-py2.py3-none-any.whl
Algorithm Hash digest
SHA256 f9fc4427a2c474bf44d9575ef42c23ee9bd1c407eb3579a25a13447f978ac726
MD5 bfa21cf6097c1769fb08aaaaf264b5b3
BLAKE2b-256 17904e6e05b54e44211618d1a0a80bd4bdc86a56954813675b95687ce8141be2

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