Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion .github/workflows/nix-skip-helper.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,6 @@ jobs:
os:
- ubuntu-latest # x86_64-linux
- ubuntu-24.04-arm # aarch64-linux
- macos-13 # x86_64-darwin
- macos-14 # aarch64-darwin
- macos-15 # aarch64-darwin
python-version:
Expand Down
1 change: 0 additions & 1 deletion .github/workflows/nix.yml
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,6 @@ jobs:
os:
- ubuntu-latest # x86_64-linux
- ubuntu-24.04-arm # aarch64-linux
- macos-13 # x86_64-darwin
- macos-14 # aarch64-darwin
- macos-15 # aarch64-darwin
python-version:
Expand Down
4 changes: 2 additions & 2 deletions compose.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@ services:
- trino

minio:
image: bitnami/minio:2025.7.23
image: bitnamilegacy/minio:2025.7.23
environment:
MINIO_ROOT_USER: accesskey
MINIO_ROOT_PASSWORD: secretkey
Expand Down Expand Up @@ -590,7 +590,7 @@ services:
- risingwave

spark-connect:
image: bitnami/spark:3.5.6
image: bitnamilegacy/spark:3.5.6
ports:
- 15002:15002
command: /opt/bitnami/spark/sbin/start-connect-server.sh --name ibis_testing --packages org.apache.spark:spark-connect_2.12:3.5.3,org.apache.iceberg:iceberg-spark-runtime-3.5_2.12:1.6.1,io.delta:delta-spark_2.12:3.3.0
Expand Down
2 changes: 1 addition & 1 deletion docs/backends/duckdb.qmd
Original file line number Diff line number Diff line change
Expand Up @@ -130,7 +130,7 @@ provider, which mimics the default behavior of the `aws` CLI and SDKs.
Ibis doesn't have an Ibis-native API for dealing with DuckDB's secrets, but you can of course
run `raw_sql` to set them up:

```{python}
```{.python}
con.raw_sql("CREATE SECRET s3 (TYPE S3, PROVIDER CREDENTIAL_CHAIN)")
```

Expand Down
24 changes: 12 additions & 12 deletions flake.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 1 addition & 2 deletions flake.nix
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@

backendDevDeps = with pkgs; [
# impala UDFs
clang_15
clang_21
cmake
ninja
# snowflake
Expand Down Expand Up @@ -158,7 +158,6 @@
PYSPARK_PYTHON = "${env}/bin/python";

AWS_PROFILE = "ibis-testing";
AWS_REGION = "us-east-2";

# needed for mssql+pyodbc
ODBCSYSINI = pkgs.writeTextDir "odbcinst.ini" ''
Expand Down
2 changes: 1 addition & 1 deletion ibis/backends/bigquery/tests/system/test_connect.py
Original file line number Diff line number Diff line change
Expand Up @@ -277,5 +277,5 @@ def test_project_id_from_default(default_credentials):


def test_project_id_missing(credentials):
with pytest.raises(ValueError, match="Project ID could not be identified.*"):
with pytest.raises(ValueError, match=r"Project ID could not be identified.*"):
ibis.bigquery.connect(credentials=credentials)
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
SELECT
approx_quantiles(IF(`t0`.`month` > 0, `t0`.`double_col`, NULL), IF(`t0`.`month` > 0, 2, NULL))[offset(1)] AS `ApproxMedian_double_col_Greater_month_0`
APPROX_QUANTILES(IF(`t0`.`month` > 0, `t0`.`double_col`, NULL), IF(`t0`.`month` > 0, 2, NULL))[offset(1)] AS `ApproxMedian_double_col_Greater_month_0`
FROM `functional_alltypes` AS `t0`
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
SELECT
approx_quantiles(`t0`.`double_col`, 2)[offset(1)] AS `ApproxMedian_double_col`
APPROX_QUANTILES(`t0`.`double_col`, 2)[offset(1)] AS `ApproxMedian_double_col`
FROM `functional_alltypes` AS `t0`
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
SELECT
[
approx_quantiles(`t0`.`double_col`, 4 IGNORE NULLS)[1],
approx_quantiles(`t0`.`double_col`, 4 IGNORE NULLS)[2],
approx_quantiles(`t0`.`double_col`, 4 IGNORE NULLS)[3]
APPROX_QUANTILES(`t0`.`double_col`, 4 IGNORE NULLS)[1],
APPROX_QUANTILES(`t0`.`double_col`, 4 IGNORE NULLS)[2],
APPROX_QUANTILES(`t0`.`double_col`, 4 IGNORE NULLS)[3]
] AS `qs`
FROM `functional_alltypes` AS `t0`
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
SELECT
approx_quantiles(`t0`.`double_col`, 4 IGNORE NULLS) AS `qs`
APPROX_QUANTILES(`t0`.`double_col`, 4 IGNORE NULLS) AS `qs`
FROM `functional_alltypes` AS `t0`
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
SELECT
approx_quantiles(`t0`.`double_col`, 2 IGNORE NULLS)[1] AS `qs`
APPROX_QUANTILES(`t0`.`double_col`, 2 IGNORE NULLS)[1] AS `qs`
FROM `functional_alltypes` AS `t0`
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
SELECT
[
approx_quantiles(`t0`.`double_col`, 4 IGNORE NULLS)[2],
approx_quantiles(`t0`.`double_col`, 4 IGNORE NULLS)[1],
approx_quantiles(`t0`.`double_col`, 4 IGNORE NULLS)[3]
APPROX_QUANTILES(`t0`.`double_col`, 4 IGNORE NULLS)[2],
APPROX_QUANTILES(`t0`.`double_col`, 4 IGNORE NULLS)[1],
APPROX_QUANTILES(`t0`.`double_col`, 4 IGNORE NULLS)[3]
] AS `qs`
FROM `functional_alltypes` AS `t0`
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
SELECT
approx_quantiles(`t0`.`double_col`, 100000 IGNORE NULLS)[33333] AS `qs`
APPROX_QUANTILES(`t0`.`double_col`, 100000 IGNORE NULLS)[33333] AS `qs`
FROM `functional_alltypes` AS `t0`
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
SELECT
farm_fingerprint(CAST('74657374206f662068617368' AS BYTES FORMAT 'HEX')) AS `Hash_b'test of hash'`
FARM_FINGERPRINT(CAST('74657374206f662068617368' AS BYTES FORMAT 'HEX')) AS `Hash_b'test of hash'`
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
SELECT
farm_fingerprint('test of hash') AS `Hash_'test of hash'`
FARM_FINGERPRINT('test of hash') AS `Hash_'test of hash'`
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
SELECT
farm_fingerprint(CAST('48656c6c6f2c20576f726c6421' AS BYTES FORMAT 'HEX')) AS `farm_fingerprint_0_b'Hello_World_'`
FARM_FINGERPRINT(CAST('48656c6c6f2c20576f726c6421' AS BYTES FORMAT 'HEX')) AS `farm_fingerprint_0_b'Hello_World_'`
Original file line number Diff line number Diff line change
@@ -1,9 +1,7 @@
SELECT
CASE
WHEN notEmpty(
extractGroups(CAST("t0"."string_col" AS String), CONCAT('(', '[\\d]+', ')'))[3 + 1]
)
THEN extractGroups(CAST("t0"."string_col" AS String), CONCAT('(', '[\\d]+', ')'))[3 + 1]
WHEN notEmpty(extractGroups(CAST("t0"."string_col" AS String), CONCAT('(', '[\\d]+', ')'))[4])
THEN extractGroups(CAST("t0"."string_col" AS String), CONCAT('(', '[\\d]+', ')'))[4]
ELSE NULL
END AS "RegexExtract(string_col, '[\\d]+', 3)"
FROM "functional_alltypes" AS "t0"
2 changes: 1 addition & 1 deletion ibis/backends/clickhouse/tests/test_client.py
Original file line number Diff line number Diff line change
Expand Up @@ -428,7 +428,7 @@ def test_subquery_with_join(con):
) AS "o"
"""
with pytest.raises(
ClickHouseDatabaseError, match="Identifier 'o.a' cannot be resolved"
ClickHouseDatabaseError, match=r"Identifier 'o\.a' cannot be resolved"
):
# https://github.com/ClickHouse/ClickHouse/issues/66133
con.sql(sql)
Expand Down
8 changes: 8 additions & 0 deletions ibis/backends/exasol/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
import contextlib
import datetime
import re
import ssl
from typing import TYPE_CHECKING, Any, Callable
from urllib.parse import unquote_plus

Expand Down Expand Up @@ -61,6 +62,7 @@ def do_connect(
host: str = "localhost",
port: int = 8563,
timezone: str = "UTC",
websocket_sslopt: Mapping[str, int] | None = None,
**kwargs: Any,
) -> None:
"""Create an Ibis client connected to an Exasol database.
Expand All @@ -77,6 +79,8 @@ def do_connect(
Port number to connect to.
timezone
The session timezone.
websocket_sslopt
Websocket SSL options, originating from
kwargs
Additional keyword arguments passed to `pyexasol.connect`.

Expand Down Expand Up @@ -114,11 +118,15 @@ def do_connect(
"Ibis requires all identifiers to be quoted to work correctly."
)

if websocket_sslopt is None:
websocket_sslopt = {"cert_reqs": ssl.CERT_NONE}

self.con = pyexasol.connect(
dsn=f"{host}:{port}",
user=user,
password=password,
quote_ident=True,
websocket_sslopt=websocket_sslopt,
**kwargs,
)
self._post_connect(timezone)
Expand Down
2 changes: 1 addition & 1 deletion ibis/backends/flink/tests/test_ddl.py
Original file line number Diff line number Diff line change
Expand Up @@ -138,7 +138,7 @@ def test_recreate_table_from_schema(
# create the same table a second time should fail
with pytest.raises(
Py4JJavaError,
match="org.apache.flink.table.catalog.exceptions.TableAlreadyExistException",
match=r"org\.apache\.flink\.table\.catalog\.exceptions\.TableAlreadyExistException",
):
new_table = con.create_table(
temp_table,
Expand Down
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
SELECT
CURRENT_TIMESTAMP() AS `TimestampNow()`
NOW() AS `TimestampNow()`
2 changes: 1 addition & 1 deletion ibis/backends/impala/tests/test_exprs.py
Original file line number Diff line number Diff line change
Expand Up @@ -590,7 +590,7 @@ def test_tpch_correlated_subquery_failure(con):

# impala can't plan this because its correlated subquery implementation is
# broken: it cannot detect the outer reference inside the inner query
with pytest.raises(HiveServer2Error, match="Could not resolve .+ reference"):
with pytest.raises(HiveServer2Error, match=r"Could not resolve .+ reference"):
con.explain(expr)


Expand Down
2 changes: 1 addition & 1 deletion ibis/backends/pyspark/tests/test_udf.py
Original file line number Diff line number Diff line change
Expand Up @@ -69,6 +69,6 @@ def my_add_one(x) -> str:

with pytest.raises(
NotImplementedError,
match="pyarrow UDFs are only supported in pyspark >= 3.5",
match=r"pyarrow UDFs are only supported in pyspark >= 3.5",
):
expr.execute()
4 changes: 1 addition & 3 deletions ibis/backends/sql/compilers/clickhouse.py
Original file line number Diff line number Diff line change
Expand Up @@ -157,7 +157,7 @@ def visit_TryCast(self, op, *, arg, to):
return self.f.accurateCastOrNull(arg, self.type_mapper.to_string(to))

def visit_ArrayIndex(self, op, *, arg, index):
return arg[self.if_(index >= 0, index + 1, index)]
return arg[self.if_(index >= 0, index, index - 1)]

def visit_ArrayRepeat(self, op, *, arg, times):
param = sg.to_identifier("_")
Expand Down Expand Up @@ -237,8 +237,6 @@ def visit_RegexExtract(self, op, *, arg, pattern, index):
if index is None:
index = 0

index += 1

then = self.f.extractGroups(arg, pattern)[index]

return self.if_(self.f.notEmpty(then), then, NULL)
Expand Down
1 change: 1 addition & 0 deletions ibis/backends/sql/dialects.py
Original file line number Diff line number Diff line change
Expand Up @@ -349,6 +349,7 @@ class Generator(Hive.Generator):
sge.Interval: lambda self, e: _interval(self, e, quote_arg=False),
sge.CurrentDate: rename_func("current_date"),
sge.TableSample: tablesample_percent_to_int,
sge.CurrentTimestamp: lambda *_: "NOW()",
}


Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
SELECT
ntile(2) OVER (ORDER BY randCanonical() ASC) - 1 AS "new_col"
NTILE(2) OVER (ORDER BY randCanonical() ASC) - 1 AS "new_col"
FROM "test" AS "t0"
LIMIT 10
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
SELECT
NTILE(2) OVER (ORDER BY RAND(UTC_TO_UNIX_MICROS(UTC_TIMESTAMP())) ASC) - 1 AS `new_col`
NTILE(2) OVER (ORDER BY RAND(UTC_TO_UNIX_MICROS(NOW())) ASC) - 1 AS `new_col`
FROM `test` AS `t0`
LIMIT 10
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,4 @@ SELECT
*
FROM `test` AS `t0`
WHERE
RAND(UTC_TO_UNIX_MICROS(UTC_TIMESTAMP())) <= 0.5
RAND(UTC_TO_UNIX_MICROS(NOW())) <= 0.5
Original file line number Diff line number Diff line change
Expand Up @@ -8,4 +8,4 @@ FROM (
`t0`.`x` > 10
) AS `t1`
WHERE
RAND(UTC_TO_UNIX_MICROS(UTC_TIMESTAMP())) <= 0.5
RAND(UTC_TO_UNIX_MICROS(NOW())) <= 0.5
Original file line number Diff line number Diff line change
Expand Up @@ -8,4 +8,4 @@ FROM (
`t0`.`x` > 10
) AS `t1`
WHERE
RAND(UTC_TO_UNIX_MICROS(UTC_TIMESTAMP())) <= 0.5
RAND(UTC_TO_UNIX_MICROS(NOW())) <= 0.5
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ SELECT
FROM (
SELECT
`t0`.`x`,
RAND(UTC_TO_UNIX_MICROS(UTC_TIMESTAMP())) AS `y`,
RAND(UTC_TO_UNIX_MICROS(UTC_TIMESTAMP())) AS `z`
RAND(UTC_TO_UNIX_MICROS(NOW())) AS `y`,
RAND(UTC_TO_UNIX_MICROS(NOW())) AS `z`
FROM `t` AS `t0`
) AS `t1`
Loading