@@ -4320,9 +4320,7 @@ def history(self) -> "pa.Table":
4320
4320
4321
4321
return pa .Table .from_pylist (history , schema = history_schema )
4322
4322
4323
- def _files (
4324
- self , snapshot_id : Optional [int ] = None , data_file_content_types : Optional [List [DataFileContent ]] = None
4325
- ) -> "pa.Table" :
4323
+ def _files (self , snapshot_id : Optional [int ] = None , data_file_filter : Optional [Set [DataFileContent ]] = None ) -> "pa.Table" :
4326
4324
import pyarrow as pa
4327
4325
4328
4326
from pyiceberg .io .pyarrow import schema_to_pyarrow
@@ -4379,7 +4377,7 @@ def _readable_metrics_struct(bound_type: PrimitiveType) -> pa.StructType:
4379
4377
for manifest_list in snapshot .manifests (io ):
4380
4378
for manifest_entry in manifest_list .fetch_manifest_entry (io ):
4381
4379
data_file = manifest_entry .data_file
4382
- if data_file_content_types and data_file .content not in data_file_content_types :
4380
+ if data_file_filter and data_file .content not in data_file_filter :
4383
4381
continue
4384
4382
column_sizes = data_file .column_sizes or {}
4385
4383
value_counts = data_file .value_counts or {}
@@ -4431,10 +4429,10 @@ def files(self, snapshot_id: Optional[int] = None) -> "pa.Table":
4431
4429
return self ._files (snapshot_id )
4432
4430
4433
4431
def data_files (self , snapshot_id : Optional [int ] = None ) -> "pa.Table" :
4434
- return self ._files (snapshot_id , [ DataFileContent .DATA ] )
4432
+ return self ._files (snapshot_id , { DataFileContent .DATA } )
4435
4433
4436
4434
def delete_files (self , snapshot_id : Optional [int ] = None ) -> "pa.Table" :
4437
- return self ._files (snapshot_id , [ DataFileContent .POSITION_DELETES , DataFileContent .EQUALITY_DELETES ] )
4435
+ return self ._files (snapshot_id , { DataFileContent .POSITION_DELETES , DataFileContent .EQUALITY_DELETES } )
4438
4436
4439
4437
4440
4438
class _ManifestMergeManager (Generic [U ]):
0 commit comments