You are viewing a plain text version of this content. The canonical link for it is here.
Posted to github@arrow.apache.org by "mbrobbel (via GitHub)" <gi...@apache.org> on 2024/05/31 11:04:07 UTC

[PR] Check length of `FIXED_LEN_BYTE_ARRAY` for `uuid` logical parquet type [arrow-rs]

mbrobbel opened a new pull request, #5821:
URL: https://github.com/apache/arrow-rs/pull/5821

   # Rationale for this change
    
   I want to add support to the `parquet` crate, so that [parquet::arrow::arrow_to_parquet_schema](https://docs.rs/parquet/latest/parquet/arrow/fn.arrow_to_parquet_schema.html) and [parquet::arrow::parquet_to_arrow_schema](https://docs.rs/parquet/latest/parquet/arrow/fn.parquet_to_arrow_schema.html) can roundtrip the canonical [`uuid` extension type](https://arrow.apache.org/docs/dev/format/CanonicalExtensions.html#uuid).
   
   It seems the `PrimitiveTypeBuilder` was missing a length (16) check for the `uuid` logical type. This PR adds the check, following the pattern used for other logical types that have a length requirement.
   
   # What changes are included in this PR?
   
   Adds a check for the length of a `PhysicalType::FIXED_LEN_BYTE_ARRAY` when it's annotated with `LogicalType::Uuid`.
   
   # Are there any user-facing changes?
   
   The builder now returns an error if the length is not 16 when trying to annotate a `PhysicalType::FIXED_LEN_BYTE_ARRAY` with `LogicalType::Uuid`.


-- 
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: github-unsubscribe@arrow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] Check length of `FIXED_LEN_BYTE_ARRAY` for `uuid` logical parquet type [arrow-rs]

Posted by "tustvold (via GitHub)" <gi...@apache.org>.
tustvold merged PR #5821:
URL: https://github.com/apache/arrow-rs/pull/5821


-- 
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: github-unsubscribe@arrow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org