From 76f3d6b45e76b9979375ef2519cc6164b07c54c1 Mon Sep 17 00:00:00 2001 From: defuz Date: Thu, 30 Oct 2014 18:40:38 +0300 Subject: [PATCH] improve TEMPLATE_AUTO_RELOAD docs --- CHANGES | 5 ++--- docs/config.rst | 11 +++++------ 2 files changed, 7 insertions(+), 9 deletions(-) diff --git a/CHANGES b/CHANGES index f028df2c..29218ade 100644 --- a/CHANGES +++ b/CHANGES @@ -23,9 +23,8 @@ Version 1.0 - Added :meth:`flask.Config.from_json`. - Added :attr:`flask.Flask.config_class`. - Added :meth:`flask.config.Config.get_namespace`. -- Added ``TEMPLATES_AUTO_RELOAD`` config key. Now by default templates will be - reloaded every time a template is requested only if the application is - running in debug mode. +- Templates are no longer automatically reloaded outside of debug mode. This + can be configured with the new ``TEMPLATES_AUTO_RELOAD`` config key. - Added a workaround for a limitation in Python 3.3's namespace loader. - Added support for explicit root paths when using Python 3.3's namespace packages. diff --git a/docs/config.rst b/docs/config.rst index d20f9a33..eaaa0ae6 100644 --- a/docs/config.rst +++ b/docs/config.rst @@ -182,12 +182,11 @@ The following configuration values are used internally by Flask: if they are not requested by an XMLHttpRequest object (controlled by the ``X-Requested-With`` header) -``TEMPLATES_AUTO_RELOAD`` If this is set to `True` every time a template - is requested Flask checks if the template was - modified and if yes, it will reload the - template. By default the value is ``None`` - which means that Flask checks template - sources only in debug mode. +``TEMPLATES_AUTO_RELOAD`` Whether to check for modifications of + the template source and reload it + automatically. By default the value is + `None` which means that Flask checks + original file only in debug mode. ``EXPLAIN_TEMPLATE_LOADING`` If this is enabled then every attempt to load a template will write an info message to the logger explaining the