disable deprecation warnings in prod (bug 654562)
This commit is contained in:
Родитель
fbc115612f
Коммит
4e5e812d04
|
@ -2,6 +2,7 @@
|
|||
import os
|
||||
import site
|
||||
import sys
|
||||
import warnings
|
||||
|
||||
|
||||
ROOT = os.path.dirname(os.path.abspath(__file__))
|
||||
|
@ -45,6 +46,9 @@ except ImportError:
|
|||
" Please come back and try again later.")
|
||||
raise
|
||||
|
||||
if not settings.DEBUG:
|
||||
warnings.simplefilter('ignore')
|
||||
|
||||
# The first thing execute_manager does is call `setup_environ`. Logging config
|
||||
# needs to access settings, so we'll setup the environ early.
|
||||
setup_environ(settings)
|
||||
|
|
Загрузка…
Ссылка в новой задаче