[ 
https://issues.apache.org/jira/browse/ARROW-640?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16408924#comment-16408924
 ] 

ASF GitHub Bot commented on ARROW-640:
--------------------------------------

AlexHagerman commented on a change in pull request #1765: ARROW-640: [Python] 
Implement __hash__ and equality for Array scalar values Arrow scalar values
URL: https://github.com/apache/arrow/pull/1765#discussion_r176290582
 
 

 ##########
 File path: python/pyarrow/scalar.pxi
 ##########
 @@ -73,6 +73,12 @@ cdef class ArrayValue(Scalar):
             raise NotImplementedError(
                 "Cannot compare Arrow values that don't support as_py()")
 
+    def __hash__(self):
 
 Review comment:
   Ticket created https://issues.apache.org/jira/browse/ARROW-2339. Anything 
else you would suggest for this PR?

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


> [Python] Arrow scalar values should have a sensible __hash__ and comparison
> ---------------------------------------------------------------------------
>
>                 Key: ARROW-640
>                 URL: https://issues.apache.org/jira/browse/ARROW-640
>             Project: Apache Arrow
>          Issue Type: Bug
>          Components: Python
>            Reporter: Miki Tebeka
>            Assignee: Alex Hagerman
>            Priority: Major
>              Labels: pull-request-available
>             Fix For: 0.10.0
>
>
> {noformat}
> In [86]: arr = pa.from_pylist([1, 1, 1, 2])
> In [87]: set(arr)
> Out[87]: {1, 2, 1, 1}
> In [88]: arr[0] == arr[1]
> Out[88]: False
> In [89]: arr
> Out[89]: 
> <pyarrow.array.Int64Array object at 0x7f8c8c739e08>
> [
>   1,
>   1,
>   1,
>   2
> ]
> {noformat}



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to