> > I'm quite sure I was driven to that PR because importing ContentTypes > was causing lots of pain with AppState not being ready. >
Whenever I see this error message pop up, it's not because code directly imports ContentTypes, but because it imports some other models.py module, which in turn imports another models.py module before any class definition is reached. ContentTypes often seems to be the first module without any dependencies. However, it's easy enough to trace the error back to the models.py file that was imported first. Especially when used in a FK, changing it to a string reference won't help, because you're still importing the model with the FK before the app registry is ready. For what it's worth, I prefer to import models and use them directly, for no particular reason other than "I like it that way". -- You received this message because you are subscribed to the Google Groups "Django developers (Contributions to Django itself)" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. Visit this group at https://groups.google.com/group/django-developers. To view this discussion on the web visit https://groups.google.com/d/msgid/django-developers/fede7124-b504-41fe-a43f-c12c6b118354%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.
