Uploaded image for project: 'Apache Arrow'
  1. Apache Arrow
  2. ARROW-17256

[Python] Can't call combine_chunks on empty ChunkedArray

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Minor
    • Resolution: Fixed
    • None
    • 10.0.0
    • Python
    • pyarrow 8.0.0
      python 3.9

    Description

      When calling:

      pa.chunked_array([], type=pa.bool_()).combine_chunks()

      I get this error:

       pyarrow/table.pxi:700: in pyarrow.lib.ChunkedArray.combine_chunks
          ???
      pyarrow/array.pxi:2868: in pyarrow.lib.concat_arrays
          ???
      pyarrow/error.pxi:144: in pyarrow.lib.pyarrow_internal_check_status
          ???
      pyarrow/error.pxi:100: in pyarrow.lib.check_status
          ???
      E   pyarrow.lib.ArrowInvalid: Must pass at least one array

      While this works:

      pa.chunked_array([pa.array([], pa.bool_())], type=pa.bool_()) 

      In the first case, it should return an empty BoolArray as well.

      Attachments

        Issue Links

          Activity

            People

              0x26dres &res
              0x26dres &res
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Time Tracking

                  Estimated:
                  Original Estimate - Not Specified
                  Not Specified
                  Remaining:
                  Remaining Estimate - 0h
                  0h
                  Logged:
                  Time Spent - 1h 20m
                  1h 20m