I will give, trying to do this:
http://docs.djangoproject.com/en/dev/topics/db/models/#be-careful-with-related-name
Using this style
This is saved as common / abstract.py
class OtherModel(models.Model):
something = Charfield(max_length=100)
class Meta:
abstract = True
class Base(models.Model):
fk_model = models.ForeignKey(OtherModel, related_name="%(app_label)s_%(class)s_related")
class Meta:
abstract = True
Then I import it into another file. Call this application /models.py
from common.abstract import Base
class ChildB(Base):
pass
I installed the "application", but not the "general". It will import beautifully without FK or M2M relationships, but when I try to add it, I get this error:
/lib/python2.6/site-packages/django/db/models/fields/related.py ", 808, init assert not to.meta.abstract," % s % s"% (self. class._ name__, to._meta.object_name)
AssertionError: ForeignKey OtherModel
, ... , - , . , , , , , .