From 7bcd532bbbfea6c06076aa7f2c23a6d9bc43e959 Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Fri, 20 Dec 2024 09:36:43 +0000 Subject: [PATCH 1/3] chore(deps): update clickhouse/clickhouse-server docker tag to v24.12.1.1614 --- compose.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/compose.yaml b/compose.yaml index 70e92f774dcc..2f35033f25aa 100644 --- a/compose.yaml +++ b/compose.yaml @@ -1,6 +1,6 @@ services: clickhouse: - image: clickhouse/clickhouse-server:24.11.1.2557-alpine + image: clickhouse/clickhouse-server:24.12.1.1614-alpine ports: - 8123:8123 # http port - 9000:9000 # native protocol port From 44fbf4458359f180a974cd928c3b53b39eba93e6 Mon Sep 17 00:00:00 2001 From: Phillip Cloud <417981+cpcloud@users.noreply.github.com> Date: Fri, 20 Dec 2024 05:00:44 -0500 Subject: [PATCH 2/3] test(clickhouse): xfail broken-on-clickhouse-only TPC-DS queries --- ibis/backends/tests/tpc/ds/test_queries.py | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/ibis/backends/tests/tpc/ds/test_queries.py b/ibis/backends/tests/tpc/ds/test_queries.py index 40d1b3650d96..11f5a108ef27 100644 --- a/ibis/backends/tests/tpc/ds/test_queries.py +++ b/ibis/backends/tests/tpc/ds/test_queries.py @@ -111,6 +111,7 @@ def test_03(date_dim, store_sales, item): @pytest.mark.notimpl( ["datafusion"], reason="Optimizer rule 'common_sub_expression_eliminate' failed" ) +@pytest.mark.notyet(["clickhouse"], reason="Broken") def test_04(customer, store_sales, catalog_sales, web_sales, date_dim): def profile(sales, *, name): char = name[0] @@ -1144,6 +1145,7 @@ def test_18( @tpc_test("ds") +@pytest.mark.notyet(["clickhouse"], reason="Broken") def test_19(date_dim, store_sales, item, customer, customer_address, store): return ( date_dim.join(store_sales, [("d_date_sk", "ss_sold_date_sk")]) @@ -1301,6 +1303,7 @@ def total_sales( @tpc_test("ds", result_is_empty=True) +@pytest.mark.notyet(["clickhouse"], reason="Broken") def test_24(store_sales, store_returns, store, item, customer, customer_address): ssales = ( store_sales.join( @@ -3259,6 +3262,7 @@ def test_63(item, store_sales, date_dim, store): @tpc_test("ds", result_is_empty=True) +@pytest.mark.notyet(["clickhouse"], reason="Broken") def test_64( catalog_sales, catalog_returns, @@ -3422,6 +3426,7 @@ def test_64( @tpc_test("ds", result_is_empty=True) +@pytest.mark.notyet(["clickhouse"], reason="Broken") def test_65(store, item, store_sales, date_dim): sa = ( store_sales.join( @@ -3751,12 +3756,13 @@ def test_71(item, web_sales, date_dim, catalog_sales, store_sales, time_dim): ) +@tpc_test("ds") @pytest.mark.notyet( ["datafusion"], raises=OperationNotDefinedError, reason="No DateDelta op defined", ) -@tpc_test("ds") +@pytest.mark.notyet(["clickhouse"], reason="Broken") def test_72( catalog_sales, inventory, @@ -3889,6 +3895,7 @@ def test_73(store_sales, date_dim, store, household_demographics, customer): @tpc_test("ds") +@pytest.mark.notyet(["clickhouse"], reason="Broken") def test_74(customer, store_sales, date_dim, web_sales): renames = { "customer_id": "c_customer_id", @@ -5058,6 +5065,7 @@ def test_94(web_sales, date_dim, customer_address, web_site, web_returns): @tpc_test("ds") +@pytest.mark.notyet(["clickhouse"], reason="Broken") def test_95(web_sales, date_dim, customer_address, web_site, web_returns): ws1 = web_sales.view() ws2 = web_sales.view() From 7bd09b8ce0b83e66460ba248e5277747778e69a3 Mon Sep 17 00:00:00 2001 From: Phillip Cloud <417981+cpcloud@users.noreply.github.com> Date: Fri, 20 Dec 2024 05:04:13 -0500 Subject: [PATCH 3/3] test(clickhouse): enable non-equijoin xpassing test --- ibis/backends/clickhouse/tests/test_select.py | 12 +++--------- 1 file changed, 3 insertions(+), 9 deletions(-) diff --git a/ibis/backends/clickhouse/tests/test_select.py b/ibis/backends/clickhouse/tests/test_select.py index 364284191ab0..afc3cd7a4784 100644 --- a/ibis/backends/clickhouse/tests/test_select.py +++ b/ibis/backends/clickhouse/tests/test_select.py @@ -6,7 +6,6 @@ from pytest import param import ibis -from ibis.backends.tests.errors import ClickHouseDatabaseError cc = pytest.importorskip("clickhouse_connect") @@ -189,16 +188,11 @@ def test_physical_table_reference_translate(alltypes, assert_sql): def test_non_equijoin(alltypes): - t = alltypes.limit(100) + t = alltypes.limit(10) t2 = t.view() expr = t.join(t2, t.tinyint_col < t2.timestamp_col.minute()).count() - - # compilation should pass - expr.compile() - - # while execution should fail since clickhouse doesn't support non-equijoin - with pytest.raises(ClickHouseDatabaseError, match="INVALID_JOIN_ON_EXPRESSION"): - expr.execute() + count = expr.to_pandas() + assert count == 45 @pytest.mark.parametrize(