Details
-
Bug
-
Status: Resolved
-
Major
-
Resolution: Fixed
-
None
Description
One way to reproduce this bug is:
>>> a = pa.array([[1, 2]])
>>> b = pa.array([None, None], type=pa.null())
>>> t1 = pa.Table.from_arrays([a], ["a"])
>>> t2 = pa.Table.from_arrays([b], ["b"])
>>> pa.concat_tables([t1, t2], promote=True)
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "pyarrow/table.pxi", line 2138, in pyarrow.lib.concat_tables
File "pyarrow/public-api.pxi", line 390, in pyarrow.lib.pyarrow_wrap_table
File "pyarrow/error.pxi", line 85, in pyarrow.lib.check_status
pyarrow.lib.ArrowInvalid: Column 0: In chunk 1: Invalid: List child array invalid: Invalid: Buffer #1 too small in array of type int64 and length 2: expected at least 16 byte(s), got 12
(because concat_tables(promote=True) will call MakeArrayOfNulls (https://github.com/apache/arrow/blob/ec3bae18157723411bb772fca628cbd02eea5c25/cpp/src/arrow/table.cc#L647))
The code here seems incorrect:
the length of the child array of a ListArray may not equal to the length of the ListArray.
Attachments
Issue Links
- links to