@@ -231,6 +231,15 @@ def __eq__(self, other: Any) -> bool:
231
231
)
232
232
233
233
234
+ @lru_cache
235
+ def _manifests (io : FileIO , manifest_list : Optional [str ]) -> List [ManifestFile ]:
236
+ """Return the manifests from the manifest list."""
237
+ if manifest_list not in (None , "" ):
238
+ file = io .new_input (manifest_list ) # type: ignore
239
+ return list (read_manifest_list (file ))
240
+ return []
241
+
242
+
234
243
class Snapshot (IcebergBaseModel ):
235
244
snapshot_id : int = Field (alias = "snapshot-id" )
236
245
parent_snapshot_id : Optional [int ] = Field (alias = "parent-snapshot-id" , default = None )
@@ -250,18 +259,9 @@ def __str__(self) -> str:
250
259
result_str = f"{ operation } id={ self .snapshot_id } { parent_id } { schema_id } "
251
260
return result_str
252
261
253
- @staticmethod
254
- @lru_cache
255
- def _manifests (io : FileIO , manifest_list : Optional [str ]) -> List [ManifestFile ]:
256
- """Return the manifests for the given snapshot."""
257
- if manifest_list not in (None , "" ):
258
- file = io .new_input (manifest_list ) # type: ignore
259
- return list (read_manifest_list (file ))
260
- return []
261
-
262
262
def manifests (self , io : FileIO ) -> List [ManifestFile ]:
263
263
"""Return the manifests for the given snapshot."""
264
- return Snapshot . _manifests (io , self .manifest_list )
264
+ return _manifests (io , self .manifest_list )
265
265
266
266
267
267
class MetadataLogEntry (IcebergBaseModel ):
0 commit comments