HonahX commented on code in PR #921:
URL: https://github.com/apache/iceberg-python/pull/921#discussion_r1678713069


##########
pyiceberg/io/pyarrow.py:
##########
@@ -2214,13 +2199,16 @@ def _dataframe_to_data_files(
         property_name=TableProperties.WRITE_TARGET_FILE_SIZE_BYTES,
         default=TableProperties.WRITE_TARGET_FILE_SIZE_BYTES_DEFAULT,
     )
+    name_mapping = table_metadata.schema().name_mapping

Review Comment:
   Sounds great! I initially raised this because we’re assigning field IDs for 
the input dataframe, which aligns with the general purpose of name mapping - to 
provide fallback IDs. On second thought, schema.name-mapping.default is more 
for the read side, so using it here may silently introduce unwanted side 
effects during write. I agree, let’s hold off on this for a while and wait for 
more discussions.



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