내가 django-nonrel
, djangotoolbox
및 GitHub의에서 mongodbengine
하고 setting.py
를 얻을 수와 syncdb 실행할 수 없습니다은 다음과 같습니다 .장고와 MongoDB를
BaoxuShis-MacBook:ptl bxshi$ python manage.py syncdb
Creating tables ...
Traceback (most recent call last):
File "manage.py", line 14, in <module>
execute_manager(settings)
File "/Library/Python/2.7/site-packages/django/core/management/__init__.py", line 438, in execute_manager
utility.execute()
File "/Library/Python/2.7/site-packages/django/core/management/__init__.py", line 379, in execute
self.fetch_command(subcommand).run_from_argv(self.argv)
File "/Library/Python/2.7/site-packages/django/core/management/base.py", line 191, in run_from_argv
self.execute(*args, **options.__dict__)
File "/Library/Python/2.7/site-packages/django/core/management/base.py", line 220, in execute
output = self.handle(*args, **options)
File "/Library/Python/2.7/site-packages/django/core/management/base.py", line 351, in handle
return self.handle_noargs(**options)
File "/Library/Python/2.7/site-packages/django/core/management/commands/syncdb.py", line 109, in handle_noargs
emit_post_sync_signal(created_models, verbosity, interactive, db)
File "/Library/Python/2.7/site-packages/django/core/management/sql.py", line 190, in emit_post_sync_signal
interactive=interactive, db=db)
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/contrib/contenttypes/management.py", line 11, in update_contenttypes
content_types = list(ContentType.objects.filter(app_label=app.__name__.split('.')[-2]))
File "/Library/Python/2.7/site-packages/django/db/models/query.py", line 84, in __len__
self._result_cache.extend(self._iter)
File "/Library/Python/2.7/site-packages/django/db/models/query.py", line 275, in iterator
for row in compiler.results_iter():
File "build/bdist.macosx-10.7-intel/egg/djangotoolbox/db/basecompiler.py", line 335, in results_iter
File "build/bdist.macosx-10.7-intel/egg/djangotoolbox/db/basecompiler.py", line 430, in build_query
File "build/bdist.macosx-10.7-intel/egg/django_mongodb_engine/compiler.py", line 160, in add_filters
File "build/bdist.macosx-10.7-intel/egg/django_mongodb_engine/compiler.py", line 168, in add_filters
ValueError: need more than 3 values to unpack
내가 mongodbengine에 대해이 오류, 그것에 대해 BBS 이야기에 스레드와 관련된 무언가를 찾을 수 있지만,이 이미 고정 말한다 :
내가 가진 오류는 점이다.
에 공식 설치 지침을 사용하거나 예를 들어, 사용하는 buildout 또는 virtualenv? 추적에서 Djangotoolbox와 django-mongodb-engine이'build/... '에서 사용되는 동안 django가'/ Library/...'에서 사용되고있는 것처럼 보입니다. – jhonkola
나는 github에서이 소스 (Django Djangotoolbox 등)를 얻은 다음'sudo python setup.py install'을 사용하여 설치합니다. 'virutalenv'는 사용되지 않았습니다. 것은'Django1.4'가'python'을 설치하는 경로에 설치되고, 다른 것들은'/ build/... '에 설치됩니다. – bxshi
github에서 Django1.4 저장소를 사용했다면 작동하지 않을 수 있습니다. django-nonrel repo를 복제하십시오. 자세한 내용은 https://groups.google.com/d/topic/django-non-relational/Hj6hmX_2KIA/discussion을 참조하십시오. – jhonkola