You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I just installed mongodb-engine and when I simply added a MongoDB database to my existing MySQL in my settings file, I get the following error when trying to address the site.
DATABASES = {
'default': {
'ENGINE': 'django.db.backends.mysql', # Add 'postgresql_psycopg2', 'mysql', 'sqlite3' or 'oracle'.
'NAME': '', # Or path to database file if using sqlite3.
'USER': '', # Not used with sqlite3.
'PASSWORD': '', # Not used with sqlite3.
'HOST': '<xx.xx.xx.xx>', # Set to empty string for localhost. Not used with sqlite3.
'PORT': '', # Set to empty string for default. Not used with sqlite3.
},
'mongotest': {
'ENGINE': 'django_mongodb_engine',
'NAME': 'mongotest',
'HOST': '',
'PORT': '27017'
}
}
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/wsgiref/handlers.py", line 85, in run
self.result = application(self.environ, self.start_response)
File "/Library/Python/2.7/site-packages/django/contrib/staticfiles/handlers.py", line 67, in call
return self.application(environ, start_response)
File "/Library/Python/2.7/site-packages/django/core/handlers/wsgi.py", line 228, in call
signals.request_started.send(sender=self.class)
File "/Library/Python/2.7/site-packages/django/dispatch/dispatcher.py", line 172, in send
response = receiver(signal=self, sender=sender, **named)
File "/Library/Python/2.7/site-packages/django/db/init.py", line 52, in reset_queries
for conn in connections.all():
File "/Library/Python/2.7/site-packages/django/db/utils.py", line 104, in all
return [self[alias] for alias in self]
File "/Library/Python/2.7/site-packages/django/db/utils.py", line 92, in getitem
backend = load_backend(db['ENGINE'])
File "/Library/Python/2.7/site-packages/django/db/utils.py", line 24, in load_backend
return import_module('.base', backend_name)
File "/Library/Python/2.7/site-packages/django/utils/importlib.py", line 35, in import_module import(name)
File "build/bdist.macosx-10.7-intel/egg/django_mongodb_engine/init.py", line 13, in
AttributeError: 'tuple' object has no attribute 'insert'
The text was updated successfully, but these errors were encountered:
Ok, so I get this same error when I remove the MySQL database and set MongoDB as default. Instead, the error occurs when I attempt to syncdb. Did I install the django-mongodb-engine incorrectly? I'm running on Mac OS X Lion.
I just installed mongodb-engine and when I simply added a MongoDB database to my existing MySQL in my settings file, I get the following error when trying to address the site.
DATABASES = {
'default': {
'ENGINE': 'django.db.backends.mysql', # Add 'postgresql_psycopg2', 'mysql', 'sqlite3' or 'oracle'.
'NAME': '', # Or path to database file if using sqlite3.
'USER': '', # Not used with sqlite3.
'PASSWORD': '', # Not used with sqlite3.
'HOST': '<xx.xx.xx.xx>', # Set to empty string for localhost. Not used with sqlite3.
'PORT': '', # Set to empty string for default. Not used with sqlite3.
},
'mongotest': {
'ENGINE': 'django_mongodb_engine',
'NAME': 'mongotest',
'HOST': '',
'PORT': '27017'
}
}
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/wsgiref/handlers.py", line 85, in run
self.result = application(self.environ, self.start_response)
File "/Library/Python/2.7/site-packages/django/contrib/staticfiles/handlers.py", line 67, in call
return self.application(environ, start_response)
File "/Library/Python/2.7/site-packages/django/core/handlers/wsgi.py", line 228, in call
signals.request_started.send(sender=self.class)
File "/Library/Python/2.7/site-packages/django/dispatch/dispatcher.py", line 172, in send
response = receiver(signal=self, sender=sender, **named)
File "/Library/Python/2.7/site-packages/django/db/init.py", line 52, in reset_queries
for conn in connections.all():
File "/Library/Python/2.7/site-packages/django/db/utils.py", line 104, in all
return [self[alias] for alias in self]
File "/Library/Python/2.7/site-packages/django/db/utils.py", line 92, in getitem
backend = load_backend(db['ENGINE'])
File "/Library/Python/2.7/site-packages/django/db/utils.py", line 24, in load_backend
return import_module('.base', backend_name)
File "/Library/Python/2.7/site-packages/django/utils/importlib.py", line 35, in import_module
import(name)
File "build/bdist.macosx-10.7-intel/egg/django_mongodb_engine/init.py", line 13, in
AttributeError: 'tuple' object has no attribute 'insert'
The text was updated successfully, but these errors were encountered: