Fokko opened a new issue, #8191:
URL: https://github.com/apache/iceberg/issues/8191

   ### Feature Request / Improvement
   
   We have the `to_bytes` in `conversions.py` to convert a Python type to 
actual bytes. We use this for writing partition values, and column metrics. It 
looks like we're inconsistent when writing logical types. When writing an uuid, 
we expect a `UUID`, but when writing a date, we expect an integer.
   
   Would be great to also allow:
   
   ```python
   from datetime import datetime, date, time
   
   to_bytes(TimestampType(), datetime(2023, 3, 1, 19, 25, 0)
   to_bytes(TimestamptzType(), datetime(2023, 3, 1, 19, 25, 0)
   to_bytes(DateType(), date(2023, 3, 1, 19, 25, 0))
   to_bytes(TimeType(), time(19, 25, 0))
   ```
   
   ### Query engine
   
   Other


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