raulcd commented on code in PR #44701:
URL: https://github.com/apache/arrow/pull/44701#discussion_r1839948746


##########
python/pyarrow/array.pxi:
##########
@@ -1174,7 +1174,12 @@ cdef class Array(_PandasConvertible):
                              "({0}) did not match the passed number "
                              "({1}).".format(type.num_fields, len(children)))
 
-        if type.num_buffers != len(buffers):
+        if type.has_variadic_buffers:
+            if type.num_buffers > len(buffers):
+                raise ValueError("Type's expected number of buffers is at 
least "
+                                 "({0}) but the passed number is "
+                                 "({1}).".format(type.num_buffers, 
len(buffers)))

Review Comment:
   Thanks, I've done it here: 
https://github.com/apache/arrow/pull/44701/commits/89e7a486ad49dff38c0365c719b1c4a7437bc1f0
 in order to update the check on the test too.



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