

@dispatch(By, Select)
def compute_up(expr, data, **kwargs):
    if (not valid_grouper(grouper.grouper)):
        raise TypeError(('Grouper must have a non-nested record or one dimensional collection datashape, got %s of type %r with dshape %s' % (expr.grouper, type(expr.grouper).__name__, expr.grouper.dshape)))
    s = alias_it(data)
    if valid_reducer(expr.apply):
        reduction = compute(expr.apply, s, post_compute=False, return_type='native')
    else:
        raise TypeError('apply must be a Summary expression')
    grouper = get_inner_columns(compute(expr.grouper, s, post_compute=False, return_type='native'))
    reduction_columns = pipe(reduction.inner_columns, map(get_inner_columns), concat)
    columns = list(unique(chain(grouper, reduction_columns)))
    if ((not isinstance(s, sa.sql.selectable.Alias)) or (hasattr(s, 'froms') and isinstance(s.froms[0], sa.sql.selectable.Join))):
        assert (len(s.froms) == 1), 'only a single FROM clause supported for now'
        (from_obj,) = s.froms
    else:
        from_obj = None
    return reconstruct_select(columns, getattr(s, 'element', s), from_obj=from_obj, group_by=grouper)

dataset/ETHPy150Open blaze/blaze/blaze/compute/sql.py compute_up/VarMisuse@28/32 `expr`->`grouper`