kou commented on a change in pull request #8805:
URL: https://github.com/apache/arrow/pull/8805#discussion_r533032135
##########
File path: python/pyarrow/compute.py
##########
@@ -155,7 +157,7 @@ def _handle_options(name, option_class, options, kwargs):
"Function {!r} expected a {} parameter, got {}"
.format(name, option_class, type(options)))
- return options
+ return option_class()
Review comment:
I'm OK that we add `SortOptins::Defaults()` with empty `sort_keys` and
use it for the default option of `sort_indices`.
It doesn't work for `RecordBatch` and `Table` but works for `Array` and
`ChunkedArray`.
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
[email protected]