Hi Shaw and Bill,
Yeap, I already have done that with no luck.
ricardo@vulcanus:~/webservices/reviewsapp$ python views.py
Traceback (most recent call last):
File "views.py", line 13, in <module>
from webservices.reviewsapp.models import *
ImportError: No module named webservices.reviewsapp.models
ricardo@vulcanus:~/webservices$ python urls.py
Traceback (most recent call last):
File "urls.py", line 8, in <module>
from reviewsapp.models import *
File "/home/ricardo/webservices/reviewsapp/models.py", line 10, in
<module>
from django.db import models
File "/usr/lib/pymodules/python2.7/django/db/__init__.py", line 14,
in <module>
if not settings.DATABASES:
File "/usr/lib/pymodules/python2.7/django/utils/functional.py", line
276, in __getattr__
self._setup()
File "/usr/lib/pymodules/python2.7/django/conf/__init__.py", line
38, 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.
ricardo@vulcanus:~/webservices$
I'm starting to became confuse. If I try the same thing with urls.py
which import two functions frow views, it shows that django settings
module is not defined and does not throw an invalid module. Basically
in urls.py python can import views.py but in views.py cannot import
models.py? Weird…
Sugestions? Append in PYTHON_PATH my app dir?
Ricardo F. Teixeira
--
You received this message because you are subscribed to the Google Groups
"Django users" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/django-users?hl=en.