私はDjangoを学んでいるので、virtualenvでpipを使用してDjangoのインストールを追跡しました。Django Book でこれを Python シェルで入力するように言われたとき、
from django import template
t = template.Template("My name is {{ name }}.")
この例外があります。これを解決する方法がわかりません。
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "django/template/base.py", line 123, in __init__
if settings.TEMPLATE_DEBUG and origin is None:
File "django/conf/__init__.py", line 53, in __getattr__
self._setup(name)
File "django/conf/__init__.py", line 46, in _setup
% (desc, ENVIRONMENT_VARIABLE))
django.core.exceptions.ImproperlyConfigured: Requested setting TEMPLATE_DEBUG,
but settings are not configured. You must either define the environment variable
DJANGO_SETTINGS_MODULE or call settings.configure() before accessing settings.
誰かが私を通り抜けることができますか?Mac OS X 10.8 を使用しています