AlenkaF commented on a change in pull request #12311:
URL: https://github.com/apache/arrow/pull/12311#discussion_r798438037



##########
File path: python/pyarrow/pandas_compat.py
##########
@@ -623,7 +623,21 @@ def _can_definitely_zero_copy(arr):
     metadata.update(pandas_metadata)
     schema = schema.with_metadata(metadata)
 
-    return arrays, schema
+    # If dataframe is empty but with RangeIndex ->
+    # remember the length of the indexes
+    n_rows = None
+    if len(arrays) == 0 and schema is not None:

Review comment:
       Oh yes, you are right. Removed it.




-- 
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: github-unsubscr...@arrow.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


Reply via email to