How can I test whether Django is running in debug mode? -
my settings file has:
debug = true the obvious method:
if debug: print 'debug' does not seem work:
global name 'debug' not defined
as mentioned in comment, need do:
from django.conf import settings print settings.debug
Comments
Post a Comment