Browse Source

Merge pull request #1577 from sprin/1102_warn_on_run

docs: run() should not be used in production
pull/1767/head
Jeff Widman 9 years ago
parent
commit
6bf42f9a84
  1. 9
      flask/app.py

9
flask/app.py

@ -779,8 +779,13 @@ class Flask(_PackageBoundObject):
return rv
def run(self, host=None, port=None, debug=None, **options):
"""Runs the application on a local development server. If the
:attr:`debug` flag is set the server will automatically reload
"""Runs the application on a local development server.
Do not use ``run()`` in a production setting. It is not intended to
meet security and performance requirements for a production server.
Instead, see :ref:`deployment` for WSGI server recommendations.
If the :attr:`debug` flag is set the server will automatically reload
for code changes and show a debugger in case an exception happened.
If you want to run the application in debug mode, but disable the

Loading…
Cancel
Save