soumya-ghosh commented on code in PR #1241:
URL: https://github.com/apache/iceberg-python/pull/1241#discussion_r1818514795


##########
pyiceberg/table/inspect.py:
##########
@@ -32,6 +33,41 @@
     from pyiceberg.table import Table
 
 
+def get_manifests_schema() -> "pa.Schema":
+    import pyarrow as pa
+
+    partition_summary_schema = pa.struct([
+        pa.field("contains_null", pa.bool_(), nullable=False),
+        pa.field("contains_nan", pa.bool_(), nullable=True),
+        pa.field("lower_bound", pa.string(), nullable=True),
+        pa.field("upper_bound", pa.string(), nullable=True),
+    ])
+
+    manifest_schema = pa.schema([
+        pa.field("content", pa.int8(), nullable=False),
+        pa.field("path", pa.string(), nullable=False),
+        pa.field("length", pa.int64(), nullable=False),
+        pa.field("partition_spec_id", pa.int32(), nullable=False),
+        pa.field("added_snapshot_id", pa.int64(), nullable=False),
+        pa.field("added_data_files_count", pa.int32(), nullable=False),
+        pa.field("existing_data_files_count", pa.int32(), nullable=False),
+        pa.field("deleted_data_files_count", pa.int32(), nullable=False),
+        pa.field("added_delete_files_count", pa.int32(), nullable=False),
+        pa.field("existing_delete_files_count", pa.int32(), nullable=False),
+        pa.field("deleted_delete_files_count", pa.int32(), nullable=False),
+        pa.field("partition_summaries", pa.list_(partition_summary_schema), 
nullable=False),
+    ])
+    return manifest_schema
+
+
+def get_all_manifests_schema() -> "pa.Schema":
+    import pyarrow as pa
+
+    all_manifests_schema = get_manifests_schema()
+    all_manifests_schema = 
all_manifests_schema.append(pa.field("reference_snapshot_id", pa.int64(), 
nullable=False))

Review Comment:
   Yes, it's not present in iceberg docs.



-- 
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