2

私はdjango 1.4をインストールしており、django-cmsを実行しています。Filer をインストールしようとしていますが、syncdb または runserver を実行すると、このエラーが発生し続けます。

 from filer.models import mixins
 ImportError: cannot import name mixins

私のsetting.pyには次のものがあります:

INSTALLED_APPS = (
'django.contrib.auth',
'django.contrib.contenttypes',
'django.contrib.sessions',
'django.contrib.sites',
'django.contrib.messages',
'django.contrib.staticfiles',
# Uncomment the next line to enable the admin:
'django.contrib.admin',
'cms', 
'mptt',
'menus', 
'south',
'sekizai', 
'ftlom',
#'cms.plugins.text',
#'cms.plugins.picture',
'cmsplugin_twitter',
'easy_thumbnails',
'filer',
#'ordered_model',
#'cmsplugin_filer_file',
#'cmsplugin_filer_folder',
'cmsplugin_filer_image',
#'cmsplugin_gallery',
'cms.plugins.video',
#'gunicorn',


# Uncomment the next line to enable admin documentation:
# 'django.contrib.admindocs',

)

ファイラーとそのすべてのプラグインを削除すると、サイトは正常に動作します。何が問題を引き起こす可能性がありますか? ありがとう

トレースバック:

Validating models...

Unhandled exception in thread started by <bound method Command.inner_run of     <django.contrib.staticfiles.management.commands.runserver.Command object at 0x1050d4fd0>>
Traceback (most recent call last):
File "/Users/Alex/.virtualenvs/FTLOM/lib/python2.7/site-   packages/django/core/management/commands/runserver.py", line 91, in inner_run
self.validate(display_num_errors=True)
File "/Users/Alex/.virtualenvs/FTLOM/lib/python2.7/site-packages/django/core/management/base.py", line 266, in validate
num_errors = get_validation_errors(s, app)
File "/Users/Alex/.virtualenvs/FTLOM/lib/python2.7/site-packages/django/core/management/validation.py", line 30, in get_validation_errors
for (app_name, error) in get_app_errors().items():
File "/Users/Alex/.virtualenvs/FTLOM/lib/python2.7/site-packages/django/db/models/loading.py", line 158, in get_app_errors
self._populate()
File "/Users/Alex/.virtualenvs/FTLOM/lib/python2.7/site-packages/django/db/models/loading.py", line 67, in _populate
self.load_app(app_name)
File "/Users/Alex/.virtualenvs/FTLOM/lib/python2.7/site-packages/django/db/models/loading.py", line 88, in load_app
models = import_module('.models', app_name)
File "/Users/Alex/.virtualenvs/FTLOM/lib/python2.7/site-packages/django/utils/importlib.py", line 35, in import_module
__import__(name)
File "/Users/Alex/.virtualenvs/FTLOM/lib/python2.7/site-packages/filer/models/__init__.py", line 2, in <module>
from filer.models.clipboardmodels import *
File "/Users/Alex/.virtualenvs/FTLOM/lib/python2.7/site-packages/filer/models/clipboardmodels.py", line 5, in <module>
from filer.models import filemodels
File "/Users/Alex/.virtualenvs/FTLOM/lib/python2.7/site-packages/filer/models/filemodels.py", line 8, in <module>
from filer.models import mixins

ImportError: 名前のミックスインをインポートできません

これは私のピップフリーズです:

Django==1.4
PIL==1.1.7
South==0.8.1
cmsplugin-filer==0.9.5
cmsplugin-twitter==1.0.4
django-classy-tags==0.4
django-cms==2.4.1
django-filer==0.9.3
django-mixins==0.0.10
django-mptt==0.5.2
django-ordered-model==0.2.0
django-polymorphic==0.5
django-sekizai==0.7
easy-thumbnails==1.3
gunicorn==17.5
html5lib==1.0b1
six==1.3.0
wsgiref==0.1.2
4

2 に答える 2

3

I ran into the same problem. The problem was hard to find but simple to solve.

After installing django-polymorphic, everything worked fine.

于 2014-06-10T10:47:57.913 に答える