fornwall commented on code in PR #936:
URL: https://github.com/apache/arrow-go/pull/936#discussion_r3582785790
##########
arrow/flight/flightsql/example/sqlite_server.go:
##########
@@ -581,6 +581,15 @@ func scalarToIFace(s scalar.Scalar) (interface{}, error) {
return val.ToTime(), nil
case *scalar.DenseUnion:
return scalarToIFace(val.Value)
+ case *scalar.Dictionary:
+ value, err := val.GetEncodedValue()
Review Comment:
> Since these arrive from Flight clients, please validate before decoding —
e.g. call val.ValidateFull() here and return the error
👍 Done that now.
> hardening scalar.GetScalar/GetEncodedValue to reject negative indices
library-wide
Split that out to #940. As I understand it `val.ValidateFull()` should still
be used here, as it gives better error messages.
> Worth adding tests for
Done.
--
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]