forked from orbit-oss/flask
Prefer flask run --debug in docs
This commit is contained in:
parent
4bc0e4943d
commit
bd26928fdb
9 changed files with 15 additions and 19 deletions
|
|
@ -47,15 +47,15 @@ Debug Mode
|
|||
|
||||
The :data:`DEBUG` config value is special because it may behave inconsistently if
|
||||
changed after the app has begun setting up. In order to set debug mode reliably, use the
|
||||
``--debug`` option on the ``flask`` command. ``flask run`` will use the interactive
|
||||
``--debug`` option on the ``flask run`` command. ``flask run`` will use the interactive
|
||||
debugger and reloader by default in debug mode.
|
||||
|
||||
.. code-block:: text
|
||||
|
||||
$ flask --app hello --debug run
|
||||
$ flask --app hello run --debug
|
||||
|
||||
Using the option is recommended. While it is possible to set :data:`DEBUG` in your
|
||||
config or code, this is strongly discouraged. It can't be read early by the ``flask``
|
||||
config or code, this is strongly discouraged. It can't be read early by the ``flask run``
|
||||
command, and some systems or extensions may have already configured themselves based on
|
||||
a previous value.
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue