I encountered a problem with Django 1.7. When I want make my migration I raise this exception : Models aren't loaded yet. I tried solution said here but it doesn't work. I saw this solution but I can't how do it with my models. Error is due to person_type field on UserProfile Class. When I removed it migrations works.
class Typo_model(BaseModel):
key = models.CharField(max_length=32, db_index=True)
text = models.CharField(max_length=255)
class UserProfile(AbstractUser, BaseModel):
person_type = models.ForeignKey(Typo_model, queryset =
Typo_model.objects.filter(cle="person_type"), verbose_name="Person type")