rahulsmahadev commented on PR #2610: URL: https://github.com/apache/iceberg-rust/pull/2610#issuecomment-4773654928
> LGTM. The change is narrow — `skip_serializing_if = "Option::is_none"` on the optional create-table fields and on `UnboundPartitionField.field_id` / `UnboundPartitionSpec.spec_id` — and deserialization is untouched, so existing payloads with explicit `null`s still round-trip (the new tests confirm this). > > One thing I checked since these two `Unbound*` types are shared more widely than the REST wire: table metadata persistence uses the _bound_ `PartitionSpec` (`PartitionSpecRef`), not `UnboundPartitionSpec`, so this doesn't alter the on-disk `metadata.json` format — the omission is confined to the request/builder-input path, which is the intended scope. Omitting an unset `field-id`/`spec-id` also matches the spec semantics for an unbound spec (those are assigned later by the server/builder), so skipping them when `None` is correct rather than just convenient. > > Minor, non-blocking: the partition tests cover the skip-when-`None` case and a `spec-id` positive case, but there's no symmetric assertion that `UnboundPartitionField.field_id` _is_ serialized when set. Worth a one-liner for completeness, but not a blocker. thanks will do the non blocking in a followup -- 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]
