1. Matt Austin
  2. django-model-utils


Carl Meyer  committed 48ad311

Document interaction of InheritanceManager and select_related. Refs #7.

  • Participants
  • Parent commits ca3ce15
  • Branches default

Comments (0)

Files changed (1)

File README.rst

View file
  • Ignore whitespace
     inheritance; it won't work for grandchild models.
 .. note::
+    The implementation of ``InheritanceManager`` uses ``select_related``
+    internally.  Due to `Django bug #16855`_, this currently means that it
+    will override any previous ``select_related`` calls on the ``QuerySet``.
+.. note::
     ``InheritanceManager`` requires Django 1.2 or later. Previous versions of
     django-model-utils included ``InheritanceCastModel``, an alternative (and
     inferior) approach to this problem that is Django 1.1
     its use in new code is discouraged.
 .. _contributed by Jeff Elmore: http://jeffelmore.org/2010/11/11/automatic-downcasting-of-inherited-models-in-django/
+.. _Django bug #16855: https://code.djangoproject.com/ticket/16855
    ``manager_from`` approach created dynamic ``QuerySet`` subclasses on the
    fly, which broke pickling of those querysets. For this reason,
    ``PassThroughManager`` is recommended instead.