I have a model similar to the following:
class Example(models.Model):
name = models.CharField(unique=True)
After running dumpdata locally (SQLite) I have:
[
{
"model": "Example",
"pk": 1,
"fields": {
"name": "Alaves"
}
},
{
"model": "Example",
"pk": 2,
"fields": {
"name": "Alavés"
}
}
]
When deploying to PA (MySQL) running a loaddata results in:
django.db.utils.IntegrityError: Problem installing fixture '/x/y/z':
(1062, "Duplicate entry 'Alav\xc3\xa9s' for key 'name'")
Both local and PA databases are using UTF8. Can't reproduce locally.
Any hints how to debug/fix? Thanks!