Skip to main content

Debug headers (and bodies) of WSGI requests and responses

Project description

This WSGI middleware will display the headers of the incoming request and the outgoing response. You can also optionally display the request or response body.

Use it like this:

from debugheaders import DebugHeaders

def application(environ, start_response):
    blah blah blah

application = DebugHeaders(application,
                           show_body=True, show_response_body=True,

show_body shows the request body, show_response_body does what you would expect, and this information is written to the stream given by output (defaults to stdout, can be any object with a .write() method, and ‘wsgi.errors’ is special and means to write to environ['wsgi.errors']).

Project details

Release history Release notifications | RSS feed

This version


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

DebugHeaders-0.1.tar.gz (2.7 kB view hashes)

Uploaded source

Supported by

AWS AWS Cloud computing Datadog Datadog Monitoring Facebook / Instagram Facebook / Instagram PSF Sponsor Fastly Fastly CDN Google Google Object Storage and Download Analytics Huawei Huawei PSF Sponsor Microsoft Microsoft PSF Sponsor NVIDIA NVIDIA PSF Sponsor Pingdom Pingdom Monitoring Salesforce Salesforce PSF Sponsor Sentry Sentry Error logging StatusPage StatusPage Status page