0

好问候 Django 的。

我是新手,在尝试确保数据库同步时,我得到了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.
4

1 回答 1

1

修复django-uuidfield==0.4在 requirements.txt

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

于 2012-11-09T10:44:06.707 回答