- Joined
- Jan 24, 2006
- Location
- South Dakota
So I have a question for you fine folks.
If I run
And run my code interactively, it works fine.
If I run just plain python shell and run the following I get errors:
I have tried googling for this error, but since I did not write the module, I do not see/cannot locate any .settings file for the module
Anyone have something to nudge me in the correct direction?
EDIT: here are the modules listed in regular python interactive mode (I have trimmed most of them for brevitiy)
If I run
Code:
/usr/lib/python2.6/site-packages/django/conf/project_template/manage.py shell
And run my code interactively, it works fine.
If I run just plain python shell and run the following I get errors:
Code:
>>> import django
>>> from django_akamai import purge
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/usr/lib/python2.6/site-packages/django_akamai-0.0.1-py2.6.egg/django_akamai/purge.py", line 48, in <module>
from django.db.models.query import QuerySet
File "/usr/lib/python2.6/site-packages/django/db/__init__.py", line 14, in <module>
if not settings.DATABASES:
File "/usr/lib/python2.6/site-packages/django/utils/functional.py", line 276, in __getattr__
self._setup()
File "/usr/lib/python2.6/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.
I have tried googling for this error, but since I did not write the module, I do not see/cannot locate any .settings file for the module
Anyone have something to nudge me in the correct direction?
EDIT: here are the modules listed in regular python interactive mode (I have trimmed most of them for brevitiy)
Code:
_codecs_tw distutils opcode sys
_collections django operator syslog
_crypt django_akamai optparse tabnanny
_csv dl os tarfile
Last edited: