icexelloss commented on code in PR #35514:
URL: https://github.com/apache/arrow/pull/35514#discussion_r1188790595
##########
python/pyarrow/tests/test_udf.py:
##########
@@ -39,6 +39,30 @@ class MyError(RuntimeError):
pass
[email protected](scope="session")
+def unary_agg_func_fixture():
+ """
+ Register a unary aggregate function
+ """
+
+ def func(ctx, x):
+ return pa.array([len(x)])
Review Comment:
This is not the ideal interface - user shouldn't need to wrap the result in
an pa.array of one row.
This is currently implemented this way to reuse the code to pass the result
back from Python to C++ code in an object that is well understood (array).
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]