Django syncdb,错误:一个或多个模型未验证

时间:2012-11-08 22:51:31

标签: django django-south

很好的问候Django's。

我是新手,在尝试确保数据库同步时,我得到Error: One or more models did not validate

我有什么想法可以解决它?

./manage.py syncdb --settings=settings.jacob
Error: One or more models did not validate:
users.userprofile: "uuid": Primary key fields cannot have null=True.
places.category: "uuid": Primary key fields cannot have null=True.
places.image: "uuid": Primary key fields cannot have null=True.
places.masterplace: "uuid": Primary key fields cannot have null=True.
places.place: "uuid": Primary key fields cannot have null=True.

./manage.py schemamigration appname --auto --settings=settings.jacob
Error: One or more models did not validate:
users.userprofile: "uuid": Primary key fields cannot have null=True.
places.category: "uuid": Primary key fields cannot have null=True.
places.image: "uuid": Primary key fields cannot have null=True.
places.masterplace: "uuid": Primary key fields cannot have null=True.
places.place: "uuid": Primary key fields cannot have null=True.

1 个答案:

答案 0 :(得分:1)

在requirements.txt

中修复django-uuidfield==0.4

https://stackoverflow.com/a/13859974/194515

相关问题