@app.before_request / @app.after_request
Also written: before_request, after_request
Flask decorators that register a function to run before every route, or after every route with the reply in hand. Kettle & Crane's `obs.py` uses them to start a timer and write one log line per request.