Skip to main content

Logging configuration for flask application

Project description

Advanced Logging configuration for flask application based on yaml file.

See logging.config

Quickstart

Install flask_logify using pip:

$ pip install Flask-Logify

Example usage

An example of log file configuration is under example folder. Only yaml format is supported.

from flask import Flask
from flask_logify import FlaskLogging


app = Flask(__name__)
app.config['LOG_FILE_CONF'] = 'log.yaml'

logging = FlaskLogging()
logging.init_app(app)

app.run()

Go to http://127.0.0.1:5000/ and see log messages like configured

Configuration

  1. LOG_FILE_CONF: (default: None) absolute path of configuration file

  2. LOG_APP_NAME: (default: flask) the PROGRAM field of the log messages

  3. LOG_LOGGER_NAME: (default: development) usually is the same of FLASK_ENV

License MIT

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

Flask-Logify-1.0.1.tar.gz (3.1 kB view details)

Uploaded Source

Built Distribution

Flask_Logify-1.0.1-py3-none-any.whl (4.5 kB view details)

Uploaded Python 3

File details

Details for the file Flask-Logify-1.0.1.tar.gz.

File metadata

  • Download URL: Flask-Logify-1.0.1.tar.gz
  • Upload date:
  • Size: 3.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.12.1 pkginfo/1.5.0.1 requests/2.21.0 setuptools/39.1.0 requests-toolbelt/0.8.0 tqdm/4.29.0 CPython/3.6.5

File hashes

Hashes for Flask-Logify-1.0.1.tar.gz
Algorithm Hash digest
SHA256 4e456b1732778832febd00923b55d3d60e5f5f9e688ee8702e2f05c85de86412
MD5 5290f60b2761f0e3a5e72b56410e50ab
BLAKE2b-256 d118f5f4c2ca1a94ead084b811329db0e1ae7e3cae93c9ba11280f48deedbd68

See more details on using hashes here.

File details

Details for the file Flask_Logify-1.0.1-py3-none-any.whl.

File metadata

  • Download URL: Flask_Logify-1.0.1-py3-none-any.whl
  • Upload date:
  • Size: 4.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.12.1 pkginfo/1.5.0.1 requests/2.21.0 setuptools/39.1.0 requests-toolbelt/0.8.0 tqdm/4.29.0 CPython/3.6.5

File hashes

Hashes for Flask_Logify-1.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 cac82c6c0aec02a90622b3e8a1c57d136ba078376b28b20148f8db967527b337
MD5 f30c9cbea9e7d45173a0d5597fdd4d9e
BLAKE2b-256 ff98c4eda2bec40a98971aaabc2e972ab526d1a6bdfaa430c10c564e72fc3d61

See more details on using hashes here.

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