You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@iceberg.apache.org by GitBox <gi...@apache.org> on 2023/01/03 19:13:19 UTC

[GitHub] [iceberg] Fokko commented on a diff in pull request #6515: Python: Refactor schema compatibility check

Fokko commented on code in PR #6515:
URL: https://github.com/apache/iceberg/pull/6515#discussion_r1060880094


##########
python/pyiceberg/io/pyarrow.py:
##########
@@ -561,15 +557,13 @@ def struct(
         fields: List[pa.Field] = []
         for field, field_array in zip(struct.fields, field_results):
             if field_array is not None:
-                array = self.cast_if_needed(field, field_array)
+                array = self._cast_if_needed(field, field_array)
                 field_arrays.append(array)
                 fields.append(pa.field(field.name, array.type, field.optional))
-            elif field.optional:

Review Comment:
   This check is done in the `check_schema_compatibility`



-- 
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-unsubscribe@iceberg.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@iceberg.apache.org
For additional commands, e-mail: issues-help@iceberg.apache.org