Open smalliao opened 10 years ago
Same error here
Traceback (most recent call last):
File "/usr/lib/python3.4/wsgiref/handlers.py", line 137, in run
self.result = application(self.environ, self.start_response)
File "/home/rubio/.virtualenvs/devel/lib/python3.4/site-packages/django/contrib/staticfiles/handlers.py", line 64, in call
return self.application(environ, start_response)
File "/home/rubio/.virtualenvs/devel/lib/python3.4/site-packages/django/core/handlers/wsgi.py", line 175, in call
signals.request_started.send(sender=self.class)
File "/home/rubio/.virtualenvs/devel/lib/python3.4/site-packages/django/dispatch/dispatcher.py", line 198, in send
response = receiver(signal=self, sender=sender, named)
File "/home/rubio/.virtualenvs/devel/lib/python3.4/site-packages/django/db/init.py", line 96, in reset_queries
for conn in connections.all():
File "/home/rubio/.virtualenvs/devel/lib/python3.4/site-packages/django/db/utils.py", line 257, in all
return [self[alias] for alias in self]
File "/home/rubio/.virtualenvs/devel/lib/python3.4/site-packages/django/db/utils.py", line 257, in
I configure my settings.py as follows:
DATABASES = { 'default': { 'ENGINE': 'mongoengine', # Add 'postgresql_psycopg2', 'mysql', 'sqlite3' or 'oracle'. 'NAME': 'study_center', # Or path to database file if using sqlite3.
The following settings are not used with sqlite3:
}
But when I run 'python manage.py runserver', the following errors occur: Traceback (most recent call last): File "manage.py", line 10, in
execute_from_command_line(sys.argv)
File "/usr/local/lib/python2.7/dist-packages/django/core/management/init.py", line 399, in execute_from_command_line
utility.execute()
File "/usr/local/lib/python2.7/dist-packages/django/core/management/init.py", line 392, in execute
self.fetch_command(subcommand).run_from_argv(self.argv)
File "/usr/local/lib/python2.7/dist-packages/django/core/management/base.py", line 242, in run_from_argv
self.execute(_args, *_options.dict)
File "/usr/local/lib/python2.7/dist-packages/django/core/management/base.py", line 280, in execute
translation.activate('en-us')
File "/usr/local/lib/python2.7/dist-packages/django/utils/translation/init.py", line 130, in activate
return _trans.activate(language)
File "/usr/local/lib/python2.7/dist-packages/django/utils/translation/trans_real.py", line 188, in activate
_active.value = translation(language)
File "/usr/local/lib/python2.7/dist-packages/django/utils/translation/trans_real.py", line 177, in translation
default_translation = _fetch(settings.LANGUAGE_CODE)
File "/usr/local/lib/python2.7/dist-packages/django/utils/translation/trans_real.py", line 159, in _fetch
app = import_module(appname)
File "/usr/local/lib/python2.7/dist-packages/django/utils/importlib.py", line 40, in import_module
import(name)
File "/usr/local/lib/python2.7/dist-packages/django/contrib/admin/init.py", line 6, in
from django.contrib.admin.sites import AdminSite, site
File "/usr/local/lib/python2.7/dist-packages/django/contrib/admin/sites.py", line 4, in
from django.contrib.admin.forms import AdminAuthenticationForm
File "/usr/local/lib/python2.7/dist-packages/django/contrib/admin/forms.py", line 6, in
from django.contrib.auth.forms import AuthenticationForm
File "/usr/local/lib/python2.7/dist-packages/django/contrib/auth/forms.py", line 17, in
from django.contrib.auth.models import User
File "/usr/local/lib/python2.7/dist-packages/django/contrib/auth/models.py", line 48, in
class Permission(models.Model):
File "/usr/local/lib/python2.7/dist-packages/django/db/models/base.py", line 96, in new
new_class.add_to_class('_meta', Options(meta, kwargs))
File "/usr/local/lib/python2.7/dist-packages/django/db/models/base.py", line 264, in add_to_class
value.contribute_to_class(cls, name)
File "/usr/local/lib/python2.7/dist-packages/django/db/models/options.py", line 124, in contribute_to_class
self.db_table = truncate_name(self.db_table, connection.ops.max_name_length())
File "/usr/local/lib/python2.7/dist-packages/django/db/init.py", line 34, in getattr
return getattr(connections[DEFAULT_DB_ALIAS], item)
File "/usr/local/lib/python2.7/dist-packages/django/db/utils.py", line 199, in getitem**
conn = backend.DatabaseWrapper(db, alias)
AttributeError: 'module' object has no attribute 'DatabaseWrapper'
If anyone knows the reason, please tell me. Thanks in advance.