﻿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
23548	Transform.relabeled_clone calls own constructor with wrong number of arguments	ris	nobody	"In https://github.com/django/django/blob/1.7/django/db/models/lookups.py#L71 :

{{{
    def relabeled_clone(self, relabels):
        return self.__class__(self.lhs.relabeled_clone(relabels))
}}}

relabeled_clone here calls Transform's own constructor with one argument (ignoring bound self), but (https://github.com/django/django/blob/1.7/django/db/models/lookups.py#L59):

{{{
    def __init__(self, lhs, lookups):
        self.lhs = lhs
        self.init_lookups = lookups[:]
}}}

__init__ takes two (non-bound) arguments, so this screws up when you try and use a QuerySet employing a custom Transform as a subquery."	Bug	closed	Database layer (models, ORM)	1.7	Normal	fixed	lookup transform orm subquery		Accepted	0	0	0	0	0	0
