NoahKusaba commented on code in PR #3303:
URL: https://github.com/apache/iceberg-rust/pull/3303#discussion_r4158683100


##########
crates/iceberg/src/arrow/schema.rs:
##########
@@ -1320,6 +1306,12 @@ impl ArrowSchemaVisitor for MetadataStripVisitor {
 /// including nested struct, list, and map fields. This is useful for schema 
comparison
 /// where metadata differences should be ignored.
 ///
+/// Two other differences are normalized away too, so that schemas that differ 
only in
+/// them compare equal once stripped:
+/// - A map's entries field is renamed to [`DEFAULT_MAP_FIELD_NAME`] and made 
non-nullable,
+///   as [`schema_to_arrow_schema`] builds it. Its key and value fields keep 
their names.

Review Comment:
   Keeping them is intentional: renaming list elements would change what 
callers see, and the map rename only exists to match `schema_to_arrow_schema`. 
I added a paragraph in 19806762f that says all other names are kept, including 
list elements, and calls out the `item` vs `element` case.



-- 
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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to