قابلتنى تلك المشكلة عندما حاولت أن أقوم بإنشاء template object بإستخدم المنصة django
>>> from django.template import Template
>>> t = Template("My name is {{ name }}.")
Traceback (most recent call last):
File "<pyshell#1>", line 1, in <module>
t = Template("My name is {{ name }}.")
File "F:\Python26\lib\site-packages\django\template\base.py", line 106, in __init__
if settings.TEMPLATE_DEBUG and origin is None:
File "F:\Python26\lib\site-packages\django\utils\functional.py", line 276, in __getattr__
self._setup()
File "F:\Python26\lib\site-packages\django\conf\__init__.py", line 40, in _setup
raise ImportError("Settings cannot be imported, because environment variable %s is undefined." % ENVIRONMENT_VARIABLE)
ImportError: Settings cannot be imported, because environment variable DJANGO_SETTINGS_MODULE is undefined.
