Skip to content

Commit f2ced4b

Browse files
committed
merge main
1 parent 8896c7c commit f2ced4b

File tree

1 file changed

+8
-8
lines changed

1 file changed

+8
-8
lines changed

pyiceberg/io/pyarrow.py

+8-8
Original file line numberDiff line numberDiff line change
@@ -1415,22 +1415,22 @@ def _task_to_record_batches(
14151415
if current_batch.num_rows == 0:
14161416
continue
14171417

1418-
yield _to_requested_schema(
1418+
result_batch = _to_requested_schema(
14191419
projected_schema,
14201420
file_project_schema,
14211421
current_batch,
14221422
downcast_ns_timestamp_to_us=True,
14231423
use_large_types=use_large_types,
14241424
)
14251425

1426-
# Inject projected column values if available
1427-
if should_project_columns:
1428-
for name, value in projected_missing_fields.items():
1429-
index = result_batch.schema.get_field_index(name)
1430-
if index != -1:
1431-
result_batch = result_batch.set_column(index, name, [value])
1426+
# Inject projected column values if available
1427+
if should_project_columns:
1428+
for name, value in projected_missing_fields.items():
1429+
index = result_batch.schema.get_field_index(name)
1430+
if index != -1:
1431+
result_batch = result_batch.set_column(index, name, [value])
14321432

1433-
yield result_batch
1433+
yield result_batch
14341434

14351435

14361436
def _read_all_delete_files(io: FileIO, tasks: Iterable[FileScanTask]) -> Dict[str, List[ChunkedArray]]:

0 commit comments

Comments
 (0)