mbutrovich commented on code in PR #2635:
URL: https://github.com/apache/iceberg-rust/pull/2635#discussion_r3501909487
##########
crates/iceberg/src/arrow/value.rs:
##########
@@ -653,14 +654,6 @@ pub(crate) fn create_primitive_array_single_element(
Ok(Arc::new(array))
}
}
- (DataType::Timestamp(TimeUnit::Microsecond, timezone), None) => {
Review Comment:
Yes. `new_null_array` builds from the `DataType`, and for timestamps the
timezone is part of `DataType::Timestamp(unit, tz)` (and precision/scale are
part of `Decimal128`), so the null array carries the exact same type the old
per-type branches produced, including `Timestamp(Nanosecond, tz)`. The thing it
does not preserve is RunEndEncoded wrapping, but the NULL-fill path uses the
plain schema type (REE is only applied on the `Some`/constant path via
`datum_to_arrow_type_with_ree`), so there is no regression. A test asserting
the full nested `DataType` (which kevinjqliu also asked for) would lock this in.
--
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]