clean out column anonymous labeling rules

Issue #2168 resolved
Mike Bayer repo owner created an issue

I.e. we want to remove:

    def label(self, name):
        if name is None:
            return self
        else:
            return super(ColumnClause, self).label(name)

from ColumnClause, so that:

c1 = column('x')
assert c1.label(None) is not c1

works as expected, instead of returning self, which doesn't make any sense. The logic within _Label should be enhanced to be smarter about when it chooses name and when it doesn't. Ideally the same result should always occur for label(c, None) versus c.label(None).

Comments (3)

  1. Log in to comment