Fokko commented on code in PR #509:
URL: https://github.com/apache/iceberg-python/pull/509#discussion_r1518833699


##########
pyiceberg/manifest.py:
##########
@@ -308,6 +308,7 @@ def data_file_with_partition(partition_type: StructType, 
format_version: Literal
             field_id=field.field_id,
             name=field.name,
             
field_type=partition_field_to_data_file_partition_field(field.field_type),
+            required=False,

Review Comment:
   What do you think of carrying this over from the field?
   
   ```suggestion
               required=field.required,
   ```
   
   I would prefer this because Avro schema's are translated to Iceberg, and 
then used in reading the files. In Avro reading an optional field is different 
than reading a required field (in the case of an optional field, it will first 
read a boolean checking if the value is there).
   
   I checked locally in tests, and there the fields are not required.



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