id,summary,reporter,owner,description,type,status,component,version,severity,resolution,keywords,cc,stage,has_patch,needs_docs,needs_tests,needs_better_patch,easy,ui_ux 20659,Error in the example for Using SingleObjectMixin with ListView,tudor.prodan@…,Susan Tan,"In this section: https://docs.djangoproject.com/en/1.5/topics/class-based-views/mixins/#using-singleobjectmixin-with-listview The example code has a mistake. Both `SingleObjectMixin.get_object` and `ListView` will use `self.get_queryset`. `get_queryset` is overwritten in the example to always return `book_set`, hence, `get_object` will always fail. `get_object` does take an optional `queryset` parameter, which, if passed, will be used instead of `self.get_queryset`, so the example may work if when calling `get_object`: {{{ def get(self, request, *args, **kwargs): - self.object = self.get_object() + self.object = self.get_object(queryset=self.model.objects) return super(PublisherDetail, self).get(request, *args, **kwargs) }}} ",Bug,closed,Documentation,1.5,Normal,fixed,,bmispelon@…,Ready for checkin,1,0,0,0,1,0