:)
我正在尝试在同一个项目上部署 django-notification 和 django-avatar,但是,当我运行 python2 manage.py syncdb 时,我收到了这个异常:
(dispersion)jorge [~/coders/desarrollo/dispersion] ~> python2 manage.py validate
python2 manage.py validate
0 errors found
(dispersion)jorge [~/coders/desarrollo/dispersion] ~> python2 manage.py syncdb
python2 manage.py syncdb
Creating tables ...
Creating table django_comments
Creating table django_comment_flags
Creating table threadedcomments_threadedcomment
Creating table threadedcomments_freethreadedcomment
Creating table threadedcomments_testmodel
Creating table notification_noticetype
Creating table notification_noticesetting
Creating table notification_noticequeuebatch
Creating table announcements_announcement
Creating table announcements_dismissal
Traceback (most recent call last):
File "manage.py", line 10, in <module>
execute_from_command_line(sys.argv)
File "/home/jorge/coders/desarrollo/dispersion/lib/python2.7/site-packages/Django-1.4.3-py2.7.egg/django/core/management/__init__.py", line 443, in execute_from_command_line
utility.execute()
File "/home/jorge/coders/desarrollo/dispersion/lib/python2.7/site-packages/Django-1.4.3-py2.7.egg/django/core/management/__init__.py", line 382, in execute
self.fetch_command(subcommand).run_from_argv(self.argv)
File "/home/jorge/coders/desarrollo/dispersion/lib/python2.7/site-packages/Django-1.4.3-py2.7.egg/django/core/management/base.py", line 196, in run_from_argv
self.execute(*args, **options.__dict__)
File "/home/jorge/coders/desarrollo/dispersion/lib/python2.7/site-packages/Django-1.4.3-py2.7.egg/django/core/management/base.py", line 232, in execute
output = self.handle(*args, **options)
File "/home/jorge/coders/desarrollo/dispersion/lib/python2.7/site-packages/Django-1.4.3-py2.7.egg/django/core/management/base.py", line 371, in handle
return self.handle_noargs(**options)
File "/home/jorge/coders/desarrollo/dispersion/lib/python2.7/site-packages/Django-1.4.3-py2.7.egg/django/core/management/commands/syncdb.py", line 110, in handle_noargs
emit_post_sync_signal(created_models, verbosity, interactive, db)
File "/home/jorge/coders/desarrollo/dispersion/lib/python2.7/site-packages/Django-1.4.3-py2.7.egg/django/core/management/sql.py", line 189, in emit_post_sync_signal
interactive=interactive, db=db)
File "/home/jorge/coders/desarrollo/dispersion/lib/python2.7/site-packages/Django-1.4.3-py2.7.egg/django/dispatch/dispatcher.py", line 172, in send
response = receiver(signal=self, sender=sender, **named)
File "/home/jorge/coders/desarrollo/dispersion/lib/python2.7/site-packages/django_avatar-1.0.5-py2.7.egg/avatar/management/__init__.py", line 9, in create_notice_types
notification.create_notice_type("avatar_updated", _("Avatar Updated"), _("avatar have been updated"))
AttributeError: 'module' object has no attribute 'create_notice_type'
(dispersion)jorge [~/coders/desarrollo/dispersion] ~>
诡异的!嗯?我什至不知道为什么会发生这个错误。有什么帮助吗?