Fokko commented on code in PR #1669:
URL: https://github.com/apache/iceberg-python/pull/1669#discussion_r1978930763


##########
pyiceberg/io/pyarrow.py:
##########
@@ -1573,11 +1561,16 @@ def _table_from_scan_task(task: FileScanTask) -> 
pa.Table:
 
         tables = [f.result() for f in completed_futures if f.result()]
 
+        arrow_schema = schema_to_pyarrow(self._projected_schema, 
include_field_ids=False)
+
         if len(tables) < 1:
-            return pa.Table.from_batches([], 
schema=schema_to_pyarrow(self._projected_schema, include_field_ids=False))
+            return pa.Table.from_batches([], schema=arrow_schema)
 
         result = pa.concat_tables(tables, promote_options="permissive")
 
+        if property_as_bool(self._io.properties, 
PYARROW_USE_LARGE_TYPES_ON_READ, False):

Review Comment:
   The idea here was to only `.cast` when the property is set. So by default it 
will don't do the cast. Thoughts? 



-- 
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: issues-unsubscr...@iceberg.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscr...@iceberg.apache.org
For additional commands, e-mail: issues-h...@iceberg.apache.org

Reply via email to