django/django — pull request #3743 by akaariai (2014-12-17 08:04:13+00:00)
Title: Fixed #24002 -- GenericRelation filtering targets related model's pk

Previously Publisher.objects.filter(book=val) would target
book.object_id if book is a GenericRelation. This is inconsistent to
filtering over reverse foreign key relations, where the target is the
related model's primary key.