Skip to main content

LogFlake Python Client

Project description

LogFlake Client Python

This repository contains the sources for the client-side components of the LogFlake product suite for applications logs and performance collection for Python applications.

🏠 [LogFlake Website](https://logflake.io) | 🔥 [CloudPhoenix Website](https://cloudphoenix.it)

Downloads

PyPI Package Name Version Downloads
LogFlake.Client.Python PyPI - Version PyPI - Downloads

Usage

Retrieve your application-key from Application Settings in LogFlake UI.

from logflake import logflake

logger = logflake.LogFlake('application-key')
logger.send_log(logflake.LogLevels.DEBUG, None, 'Hello World')

logger.shutdown()

Use logging handler example

LOGGING = {
    "version": 1,
    "formatters": {
        "logflake": {
            "()": "django.utils.log.ServerFormatter",
            "format": f"%(name)s %(module)s.%(funcName)s() %(message)s",
        },
    },
    "handlers": {
        "logflake": {
            "class": "logflake.logflake.LogFlakeHandler", # REQUIRED
            "app_id": "application-key",                  # REQUIRED
            "formatter": "logflake",                      # OPTIONAL: Use custom formatter
            "server": "https://app.logflake.io",          # OPTIONAL: Use custom logging server
            "level": logging.ERROR,                       # OPTIONAL: Set minimum severity
        }
    },
    "root": {
        "handlers": ["logflake"], # REQUIRED
    },
}

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

logflake-1.2.0.tar.gz (3.8 kB view details)

Uploaded Source

Built Distribution

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

logflake-1.2.0-py3-none-any.whl (4.0 kB view details)

Uploaded Python 3

File details

Details for the file logflake-1.2.0.tar.gz.

File metadata

  • Download URL: logflake-1.2.0.tar.gz
  • Upload date:
  • Size: 3.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.0.0 CPython/3.12.2

File hashes

Hashes for logflake-1.2.0.tar.gz
Algorithm Hash digest
SHA256 e5090fef163fb84c45c585ba1af45fa2c3333b0d80a768682240745b3e5d4d60
MD5 7a73988eba132ad24d7da3154ab36bb6
BLAKE2b-256 5b98be86f1a7b1f5f94a547e82f26644c32e741931242030316af94789b69f58

See more details on using hashes here.

File details

Details for the file logflake-1.2.0-py3-none-any.whl.

File metadata

  • Download URL: logflake-1.2.0-py3-none-any.whl
  • Upload date:
  • Size: 4.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.0.0 CPython/3.12.2

File hashes

Hashes for logflake-1.2.0-py3-none-any.whl
Algorithm Hash digest
SHA256 7b40266bd84c4d16c1fce102c44ed0701c2d8d011ab06f99e1e92269a56e8c14
MD5 c8de5cd630604c0e2434f6c3d8969b4c
BLAKE2b-256 487a068307f2eb044db840e08d8175ca83557400781094ff4155f6f080189b4a

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