def get_grouping(self):
        qn = self.quote_name_unless_alias
        result, params = [], []
        if self.group_by is not None:
            group_by = self.group_by or []

            extra_selects = []
            for extra_select, extra_params in self.extra_select.itervalues():
                extra_selects.append(extra_select)
                params.extend(extra_params)
            for col in group_by + self.related_select_cols + extra_selects:
                if isinstance(col, (list, tuple)):
                    result.append('%s.%s' % (qn(col[0]), qn(col[1])))
                elif hasattr(col, 'as_sql'):
                    result.append(col.as_sql(qn))
                else:
                    result.append(str(col))
        return result, params
Called to remap or validate any path, whether input or output
dataset/ETHPy150Open CollabQ/CollabQ/vendor/django/db/models/sql/query.py/BaseQuery.get_grouping--crossover with--dataset/ETHPy150Open chalasr/Flask-P2P/venv/lib/python2.7/site-packages/setuptools/sandbox.py/AbstractSandbox._validate_path