neilconway opened a new pull request, #25543:
URL: https://github.com/apache/datafusion/pull/25543

   ## Which issue does this PR close?
   
   - N/A
   
   ## Rationale for this change
   
   `ScalarValue::Map` has an unfortunate property: it exposes the `keys()` and 
`values()` methods from the underlying Arrow `MapArray`, but those methods 
return all of the keys/values in the backing array, _not_ just keys/values in 
the visible span. As a result, calling `keys()` on a `ScalarValue::Map` can 
return values outside the logical content of the scalar map.
   
   Fix an instance of this bug in the substrait serialization code.
   
   ## What changes are included in this PR?
   
   * Fix substrait map literal serialization bug
   * Add unit test
   
   ## What is the testing strategy for this PR?
   
   Existing tests pass, new test added.
   
   ## Are there any user-facing changes?
   
   No, aside from fixing the bug.
   


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

Reply via email to