在 Linux 机器上,在 Django 网站上工作。最近买了一台新电脑,正在运行 Windows 8。我正在使用 PyCharm,并且正在尝试第一次启动本地服务器。我安装的最后一个依赖项是 zinnia,现在它给了我这个奇怪的错误。这是 PyCharm 在不工作之前给我的输出。
Unhandled exception in thread started by <bound method Command.inner_run of
<django.contrib.staticfiles.management.commands.runserver.Command object at 0x029643F0>>
Traceback (most recent call last):
File "C:\Python27\lib\site-packages\django\core\management\commands\runserver.py",
line 92, in inner_run
self.validate(display_num_errors=True)
File "C:\Python27\lib\site-packages\django\core\management\base.py", line 280, in
validate
num_errors = get_validation_errors(s, app)
File "C:\Python27\lib\site-packages\django\core\management\validation.py", line 35, in
get_validation_errors
for (app_name, error) in get_app_errors().items():
File "C:\Python27\lib\site-packages\django\db\models\loading.py", line 166, in
get_app_errors
self._populate()
File "C:\Python27\lib\site-packages\django\db\models\loading.py", line 72, in _populate
self.load_app(app_name, True)
File "C:\Python27\lib\site-packages\django\db\models\loading.py", line 96, in load_app
models = import_module('.models', app_name)
File "C:\Python27\lib\site-packages\django\utils\importlib.py", line 35, in
import_module
__import__(name)
File "C:\Python27\lib\site-packages\django_blog_zinnia-0.12.3-py2.7.egg\zinnia\models
\__init__.py", line 2, in <module>
from zinnia.models.entry import Entry
File "C:\Python27\lib\site-packages\django_blog_zinnia-0.12.3-py2.7.egg\zinnia\models
\entry.py", line 23, in <module>
from zinnia.models.author import Author
File "C:\Python27\lib\site-packages\django_blog_zinnia-0.12.3-py2.7.egg\zinnia\models
\author.py", line 10, in <module>
class Author(User):
File "C:\Python27\lib\site-packages\django\db\models\base.py", line 123, in __new__
raise TypeError("%s cannot proxy the swapped model '%s'." % (name, base_meta.swapped))
TypeError: Author cannot proxy the swapped model 'main.MyUser'.