[ https://issues.apache.org/jira/browse/ARROW-3532?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16773030#comment-16773030 ]
Antoine Pitrou commented on ARROW-3532: --------------------------------------- Currently: {code:python} >>> ty = pa.struct([ ...: pa.field('a', pa.int16()), ...: pa.field('a', pa.float64()), ...: pa.field('b', pa.int32()), ...: ]) ...: >>> ty['a'] >>> >>> Traceback (most recent call last): File "<ipython-input-4-3cc8818c97f5>", line 1, in <module> ty['a'] File "pyarrow/types.pxi", line 276, in pyarrow.lib.StructType.__getitem__ return self.field_by_name(i) File "pyarrow/types.pxi", line 254, in pyarrow.lib.StructType.field_by_name raise KeyError(name) KeyError: 'a' {code} > [Python] Schema, StructType, StructArray field retrieval by name should raise > warning or exception for multiple matches > ----------------------------------------------------------------------------------------------------------------------- > > Key: ARROW-3532 > URL: https://issues.apache.org/jira/browse/ARROW-3532 > Project: Apache Arrow > Issue Type: Improvement > Components: Python > Reporter: Krisztian Szucs > Assignee: Antoine Pitrou > Priority: Major > Fix For: 0.13.0 > > > {code} > ty = pa.struct([ > pa.field('a', pa.int16()), > pa.field('a', pa.float64()) > ]) > ty['a'] > {code} -- This message was sent by Atlassian JIRA (v7.6.3#76005)