jorisvandenbossche commented on code in PR #40661:
URL: https://github.com/apache/arrow/pull/40661#discussion_r1530447135


##########
python/pyarrow/src/arrow/python/arrow_to_pandas.cc:
##########
@@ -2320,6 +2329,17 @@ class ConsolidatedBlockCreator : public 
PandasBlockCreator {
       if (arrays_[column_index]->type()->id() == Type::EXTENSION) {
         arrays_[column_index] = GetStorageChunkedArray(arrays_[column_index]);
       }
+      // In case of a RunEndEncodedArray default to the storage type
+      else if (arrays_[column_index]->type()->id() == Type::RUN_END_ENCODED) {
+        ARROW_ASSIGN_OR_RAISE(Datum decoded,
+                              compute::RunEndDecode(arrays_[column_index]));

Review Comment:
   I think you should be able to write it such that `GetDecodedChunkedArray` 
returns a Result, and then still use that here. For example, it should be 
possible to do something like `ARROW_ASSIGN_OR_RAISE(arrays_[column_index], 
GetDecodedChunkedArray(arrays_[column_index]))`, I think



-- 
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]

Reply via email to