[ 
https://issues.apache.org/jira/browse/ARROW-13158?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Antoine Pitrou resolved ARROW-13158.
------------------------------------
    Fix Version/s: 5.0.0
       Resolution: Fixed

Issue resolved by pull request 10591
[https://github.com/apache/arrow/pull/10591]

> [Python] Fix repr and contains of StructScalar with duplicate field names
> -------------------------------------------------------------------------
>
>                 Key: ARROW-13158
>                 URL: https://issues.apache.org/jira/browse/ARROW-13158
>             Project: Apache Arrow
>          Issue Type: Improvement
>          Components: Python
>            Reporter: Joris Van den Bossche
>            Assignee: Joris Van den Bossche
>            Priority: Major
>              Labels: pull-request-available
>             Fix For: 5.0.0
>
>          Time Spent: 2h
>  Remaining Estimate: 0h
>
> Broken off from ARROW-9997
> When having duplicate fields, the repr fails:
> {code}
> In [28]: s = pa.scalar([('a', 1), ('b', 2), ('a', 3)], pa.struct([('a', 
> 'int64'), ('b', 'int64'), ('a', 'int64')]))
> In [29]: 0 in s
> Out[29]: True
> In [30]: s
> ....
> KeyError: 'a'
> {code}
> In addition, the contains ({{in}}) operation also shouldn't accept integers 
> (this is also the case for non-duplicate fields)



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

Reply via email to