Skip to content

Commit 3ddab7f

Browse files
committed
switch golden tests to ibis compiler
1 parent 9f497a6 commit 3ddab7f

File tree

1 file changed

+4
-5
lines changed

1 file changed

+4
-5
lines changed

bigframes/testing/compiler_session.py

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -17,15 +17,14 @@
1717

1818
import bigframes.core
1919
import bigframes.core.compile as compile
20+
from bigframes.core.compile.ibis_compiler import ibis_compiler
2021
import bigframes.session.executor
2122

2223

2324
@dataclasses.dataclass
2425
class SQLCompilerExecutor(bigframes.session.executor.Executor):
2526
"""Executor for SQL compilation using sqlglot."""
2627

27-
compiler = compile.sqlglot
28-
2928
def to_sql(
3029
self,
3130
array_value: bigframes.core.ArrayValue,
@@ -38,9 +37,9 @@ def to_sql(
3837

3938
# Compared with BigQueryCachingExecutor, SQLCompilerExecutor skips
4039
# caching the subtree.
41-
return self.compiler.compile_sql(
42-
compile.CompileRequest(array_value.node, sort_rows=ordered)
43-
).sql
40+
request = compile.CompileRequest(array_value.node, sort_rows=ordered)
41+
compiled = ibis_compiler.compile_sql(request)
42+
return compiled.sql
4443

4544
def execute(
4645
self,

0 commit comments

Comments
 (0)