Ticket #436 (closed defect: fixed)
Migration Fails with Proxy Model
|Reported by:||physicsrob@…||Owned by:||andrew|
It appears that there is a problem migrating applications that have a model with a foreignkey pointing to a proxy for django's User model.
Here is the example I'm trying with:
If you try to create a migration for this application you will get a failure:
south.exceptions.ORMBaseNotIncluded: Cannot find ORM base auth.user
I'm very new to south, so excuse my poor explanation, but it appears that the problem is in the migration's 'models' dictionary. It seems that there needs to be an entry for 'auth.user', but that never gets added.
Fortunately there is a workaround. If you add a dummy table to the application with a ForeignKey? on the User, south will properly add the 'auth.user' entry to the migrations 'models' dictionary.
user = models.ForeignKey?(User)
- Status changed from new to closed
- Resolution set to fixed
- Milestone set to 0.7.1