[Python][C++] pyarrow.repeat returns an invalid array when a chunked array is required.
Open
Component: Python
good-first-issue
Type: bug
- Dominant language
- C++
- Stars
- 17.1k
- Forks
- 4.3k
- Avg merge
- 3d 13h
- Merged PRs (30d)
- 88
Description
### Describe the bug, including details regarding any error messages, version, and platform.
pyarrow.repeat silently fails and returns an invalid array when the result cannot fit in a single chunk.
```
import sys
import pyarrow as pa
print(f"{sys.version}")
print(f"{pa.__version__=}")
array = pa.repeat("?", 2**31 - 1)
print(array)
array = pa.repeat("?", 2**31)
print(array)
```
output:
```
3.9.12 (main, Jan 1 2020, 00:00:00)
[GCC 8.3.0]
pa.__version__='12.0.0'
[
"?",
"?",
...
"?",
"?",
]
```
### Component(s)
Python
Contributor guide
Assessment
This issue has not been assessed yet.