You are viewing a plain text version of this content. The canonical link for it is here.
Posted to pylucene-dev@lucene.apache.org by "Andi Vajda (JIRA)" <ji...@apache.org> on 2017/10/18 23:40:00 UTC

[jira] [Resolved] (PYLUCENE-39) JArrays are no longer sliceable under Python 3.

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

Andi Vajda resolved PYLUCENE-39.
--------------------------------
    Resolution: Fixed

fixed in rev 1812596

> JArrays are no longer sliceable under Python 3.
> -----------------------------------------------
>
>                 Key: PYLUCENE-39
>                 URL: https://issues.apache.org/jira/browse/PYLUCENE-39
>             Project: PyLucene
>          Issue Type: Bug
>         Environment: JCC 3
>            Reporter: A. Coady
>            Priority: Minor
>
> JArray objects use the legacy __getslice__ implementation, and hence aren't sliceable in Python 3.
> {code}
> In []: lucene.JArray_byte(b'abc')[:]
> ...
> TypeError: sequence index must be integer, not 'slice'
> {code}
> I'm not necessarily advocating that they should be sliceable, just that it's a regression.  It's also worth noting that slices returned Python sequences, not JArray objects, which I think is worth revisiting if it's going to be re-implemented anyway.



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)