Skip to content
Myr

Merge branch 'master' of github.com:mitsuhiko/flask

Before adoption: this commit came in with the history the project adopted, so no landing records it.

authored by Armin Ronacher · committed by Armin Ronacher · parents 9d899cd, 2d78a33 · Browse files · 3 files+2 added−3 removed
This commit

State

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Diff stats

3 files+2 added−3 removed

  • other:+2 added−3 removed

3 files+2 added−3 removed

modified:docs/tutorial/dbcon.rst+1 added-1 removed
7 unmodified lines
8connection in all our functions so it makes sense to initialize them9before each request and shut them down afterwards.1011Flask allows us to do that with the :meth:`~flask.Flask.before_request`,12:meth:`~flask.Flask.teardown_request` and :meth:`~flask.Flask.teardown_request`12:meth:`~flask.Flask.after_request` and :meth:`~flask.Flask.teardown_request`13decorators::1415 @app.before_request16 def before_request():
25 unmodified lines
modified:flask/app.py+1 added-1 removed
110 unmodified lines
111 #: This attribute can also be configured from the config with the `DEBUG`112 #: configuration key. Defaults to `False`.113 debug = ConfigAttribute('DEBUG')114115 #: The testing flask. Set this to `True` to enable the test mode of115 #: The testing flag. Set this to `True` to enable the test mode of116 #: Flask extensions (and in the future probably also Flask itself).117 #: For example this might activate unittest helpers that have an118 #: additional runtime cost which should not be enabled by default.119 #:
1193 unmodified lines
modified:flask/ctx.py-1 removed
10 unmodified lines
1112from werkzeug.exceptions import HTTPException1314from .globals import _request_ctx_stack15from .session import _NullSession15from .module import blueprint_is_module161718class _RequestGlobals(object):
128 unmodified lines