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

   # Which issue does this PR close?
   
   Closes #7607.
   
   # Rationale for this change
   
   Previously, the `is_null` method on `DictionaryArray` only considered nulls 
in the keys buffer, which could result in inaccurate null reporting when the 
dictionary values themselves contained nulls. This change ensures that nulls 
are correctly propagated by also checking the referenced value in the 
dictionary array.
   
   Accurately reflecting null semantics is essential for correctness in 
downstream operations such as filtering, joins, and aggregations.
   
   # What changes are included in this PR?
   
   - Implemented a custom `is_null` method in `DictionaryArray` that checks 
both the key and its referenced value.
   - Implemented a corresponding override in `TypedDictionaryArray` to delegate 
to the dictionary's `is_null`.
   - Added a unit test `test_is_null_considers_dictionary_values` to verify the 
combined null behavior in both raw and typed dictionary arrays.
   
   # Are there any user-facing changes?
   
   Yes, this changes the behavior of `is_null` for `DictionaryArray` and 
`TypedDictionaryArray`. Users relying on the previous behavior (which only 
checked key nulls) may observe different results if dictionary values contain 
nulls.
   
   This aligns the behavior more closely with expected null propagation 
semantics but should be considered a behavioral fix that might impact some 
logic in downstream code.
   


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