From d97ad13dca83466c37bb05e9510ef5c015d30356 Mon Sep 17 00:00:00 2001 From: Phillip Cloud <417981+cpcloud@users.noreply.github.com> Date: Tue, 19 Sep 2023 08:04:45 -0400 Subject: [PATCH] chore: remove `remove_aliases` kwarg from duckdb compiler --- ibis/backends/duckdb/compiler/relations.py | 2 +- ibis/backends/duckdb/compiler/values.py | 8 +++----- 2 files changed, 4 insertions(+), 6 deletions(-) diff --git a/ibis/backends/duckdb/compiler/relations.py b/ibis/backends/duckdb/compiler/relations.py index 26e80c4dbe9e9..da84e0665b21c 100644 --- a/ibis/backends/duckdb/compiler/relations.py +++ b/ibis/backends/duckdb/compiler/relations.py @@ -65,7 +65,7 @@ def _selection(op: ops.Selection, *, table, needs_alias=False, aliases, **kw): @translate_rel.register(ops.Aggregation) def _aggregation(op: ops.Aggregation, *, table, **kw): tr_val = partial(translate_val, **kw) - tr_val_no_alias = partial(translate_val, render_aliases=False, **kw) + tr_val_no_alias = partial(translate_val, **kw) by = tuple(map(tr_val, op.by)) metrics = tuple(map(tr_val, op.metrics)) diff --git a/ibis/backends/duckdb/compiler/values.py b/ibis/backends/duckdb/compiler/values.py index 4cc9319dad245..44c2a3d86aa30 100644 --- a/ibis/backends/duckdb/compiler/values.py +++ b/ibis/backends/duckdb/compiler/values.py @@ -52,11 +52,9 @@ def _column(op, *, aliases, **_): @translate_val.register(ops.Alias) -def _alias(op, render_aliases: bool = True, **kw): - val = translate_val(op.arg, render_aliases=render_aliases, **kw) - if render_aliases: - return sg.alias(val, op.name) - return val +def _alias(op, **kw): + val = translate_val(op.arg, **kw) + return sg.alias(val, op.name) ### Literals