scovich opened a new issue, #8420:
URL: https://github.com/apache/arrow-rs/issues/8420

   **Describe the bug**
   
   When converting strongly-typed arrow arrays to binary variant, 
`typed_value_to_variant` has the following code, which unconditionally treats 
all 16-byte values as UUID:
   ```rust
           DataType::FixedSizeBinary(binary_len) => {
               let array = typed_value.as_fixed_size_binary();
               // Try to treat 16 byte FixedSizeBinary as UUID                  
                                                                                
                                                                                
                                  
               let value = array.value(index);
               if *binary_len == 16 {
                   if let Ok(uuid) = Uuid::from_slice(value) {
                       return Variant::from(uuid);
                   }
               }                                                                
                                                                                
                                                                                
                                  
               let value = array.value(index);
               Variant::from(value)
           }
   ```
   
   **To Reproduce**
   
   Create a `FixedSizeBinaryArray` with length 16 and convert to variant.
   
   **Expected behavior**
   
   UUIDs should only be produced if the UUID extension type is present.
   


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

Reply via email to