Skip to main content

A Pump middleware for adding flash message support via sessions.

Project description

# pump-flash

pump-flash is a [Pump](http://adeel.github.com/pump) middleware for adding flash message support via sessions. It requires you to be using the [pump.middleware.session](https://github.com/adeel/pump/blob/master/pump/middleware/session.py) middleware already.

## Installation

To install, type

$ pip install pump-flash

or to grab it from GitHub:

$ git clone git://github.com/adeel/pump-flash.git $ cd pump-flash $ python setup.py install

## Usage

Just wrap your app with pump_flash.wrap_flash.

Before your app is called, the middleware adds a flash key to the request that contains the current flash dict. Then your app is called, and the session is updated to the new value of request[“flash”]. Note that request[“flash”] is actually a dict-like object whose values disappear after the first access.

Project details


Download files

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

Files for pump-flash, version 0.0.1
Filename, size File type Python version Upload date Hashes
Filename, size pump_flash-0.0.1-py2.7.egg (2.5 kB) File type Egg Python version 2.7 Upload date Hashes View
Filename, size pump-flash-0.0.1.tar.gz (1.5 kB) File type Source Python version None Upload date Hashes View

Supported by

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