尝试在 Django settings.py 中配置 TEMPLATE_CONTEXT PROCESSORS 时,出现以下错误:
Exception Value: Error importing request processor module
django.contrib.messages.context_processors.messagesdjango.core.context_processors:
"No module named 'django.contrib.messages.context_processors.messagesdjango';
django.contrib.messages.context_processors is not a package"
我的 TEMPLATE_CONTEXT_PROCESSORS 如下:(Django 版本:1.5.1)
TEMPLATE_CONTEXT_PROCESSORS = (
"django.contrib.auth.context_processors.auth",
"django.core.context_processors.debug",
"django.core.context_processors.i18n",
"django.core.context_processors.media",
"django.core.context_processors.static",
"django.core.context_processors.tz",
"django.contrib.messages.context_processors.messages"
"django.core.context_processors.request",
)