Opened 7 years ago

Closed 7 years ago

Last modified 7 years ago

#28096 closed Bug (fixed)

Cannot Prefetch() when queryset has ModelIterable subclass

Reported by: Claude Paroz Owned by: nobody
Component: Database layer (models, ORM) Version: 1.11
Severity: Normal Keywords: regression
Cc: Triage Stage: Ready for checkin
Has patch: yes Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: yes UI/UX: no

Description

I have a manager with a custom ModelIterable subclass. Unfortunately, I cannot prefetch on it because of the queryset._iterable_class is not ModelIterable line introduced in [7ec330eeb96d0874949eacb8ed1bbb97e11807e1].

Could that line make use of issubclass instead?

Change History (4)

comment:1 by Claude Paroz, 7 years ago

Has patch: set

comment:2 by Tim Graham, 7 years ago

Triage Stage: UnreviewedReady for checkin

comment:3 by Claude Paroz <claude@…>, 7 years ago

Resolution: fixed
Status: newclosed

In 43b4a161:

Fixed #28096 -- Allowed prefetch calls with ModelIterable subclasses

Regression in 7ec330eeb96d0874949eacb8ed1bbb97e11807e1.
Thanks Tim Graham for the review.

comment:4 by Claude Paroz <claude@…>, 7 years ago

In 61e883c:

[1.11.x] Fixed #28096 -- Allowed prefetch calls with ModelIterable subclasses

Regression in 7ec330eeb96d0874949eacb8ed1bbb97e11807e1.
Thanks Tim Graham for the review.
Backport of 43b4a1618ed85151494d68778a1bb6304ce1cb79 from master.

Note: See TracTickets for help on using tickets.
Back to Top