1fanwang opened a new issue, #51293: URL: https://github.com/apache/arrow/issues/51293
### Describe the bug, including details regarding any error messages, version, and platform. `pyarrow.dataset.get_partition_keys` takes an `Expression` but does not reject `None`, so passing it dereferences a null pointer and terminates the interpreter rather than raising. ```python import pyarrow.dataset as ds ds.get_partition_keys(None) ``` ```console $ python -c "import pyarrow.dataset as ds; ds.get_partition_keys(None)"; echo "exit=$?" Bus error: 10 exit=138 ``` The same call through the private alias `ds._get_partition_keys(None)` crashes identically. This is the same class of problem as GH-51042 and GH-51043, where a required Arrow wrapper argument was not declared `not None` at the Cython boundary. A sweep of the remaining Cython bindings for required wrapper-typed parameters without `not None` found this as the one still reachable from a public entry point. Expected behavior is a `TypeError`, consistent with other typed PyArrow APIs. PyArrow 25.0.1, CPython 3.11, macOS arm64. ### Component(s) Python -- 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]
