From bca6fa6428362363789a919e0426f957feb9fb83 Mon Sep 17 00:00:00 2001 From: Tim Saucer Date: Sat, 9 Nov 2024 14:28:27 -0500 Subject: [PATCH] Resolve errors in doc building --- python/datafusion/functions.py | 2 +- python/datafusion/udf.py | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/python/datafusion/functions.py b/python/datafusion/functions.py index 9552876f8..a1b6b20a6 100644 --- a/python/datafusion/functions.py +++ b/python/datafusion/functions.py @@ -924,7 +924,7 @@ def to_timestamp(arg: Expr, *formatters: Expr) -> Expr: return f.to_timestamp(arg.expr) formatters = [f.expr for f in formatters] - return Expr(f.to_timestamp(arg.expr.cast(pa.string()), *formatters)) + return Expr(f.to_timestamp(arg.expr, *formatters)) def to_timestamp_millis(arg: Expr, *formatters: Expr) -> Expr: diff --git a/python/datafusion/udf.py b/python/datafusion/udf.py index 291ef2bae..d9d994b22 100644 --- a/python/datafusion/udf.py +++ b/python/datafusion/udf.py @@ -229,6 +229,7 @@ def udaf( which this UDAF is used. The following examples are all valid. .. code-block:: python + import pyarrow as pa import pyarrow.compute as pc