Skip to main content

Kudzu - set of utilities for better logging in WSGI applications

Kudzu provides WSGI middleware and logging handlers which:

  • Read or generate unique ID for each request and include this request ID in emitted log records.

  • Sends request ID in response using X-Request-ID header. This ID is also made globally available and can included when calling other applications or components.

  • Logs all requests and responses using Python standard logging.

Kudzu is framework independent and it is compatible with both Python 2 (tested with 2.6 and 2.7) and Python 3 (tested with 3.3 and 3.4).

Installation

Kudzu can be installed using pip (or easy_install) from PyPI:

$ pip install kudzu

Alternatively you can download and extract tarball and install the package manually:

$ python setup.py install

Placing the package to your PYTHONPATH should also work.

Example usage

# Apply middleware to WSGI application
application = kudzify_app(application)

# Include request ID and remote address in log records
kudzify_logger(format='[%(addr)s|%(rid)s] %(levelname)s:%(message)s')

See example.py for more information.

Testing

Tests for all supported Python versions can be run using Tox:

$ tox

Alternativelly you can install Kudzu with test dependencies pytest and Werkzeug and run tests manually:

$ py.test

Metadata

Release files for Kudzu 0.1

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

Source distribution (sdist)

Source distribution for Kudzu 0.1
File Size Uploaded Provenance
Kudzu-0.1.tar.gz 12.2 kB Without provenance Details

Release files / Kudzu-0.1.tar.gz

Download URL Kudzu-0.1.tar.gz
Size 12.2 kB
Tags Source
SHA-256 checksum
How to use checksums
a3659e8d08a9db6606a5da43cf7cc502d498fc1c1c8de77c2850ea2ff258aa43
BLAKE2b-256 checksum
How to use checksums
ca7f00ac678b7f98a0129eee77704e66a9dd1c72724284060541cf70b1c7827d
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No

Security for Kudzu 0.1

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

0.1 This release

1 release file No provenance

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