[PyQt] PyQt v5.11 and Python v3.5 (was: Re: ANN: PyQt v5.11.2 and SIP v4.19.11 Released)

Phil Thompson phil at riverbankcomputing.com
Wed Jul 4 12:44:44 BST 2018


On 4 Jul 2018, at 12:28 pm, Florian Bruhin <me at the-compiler.org> wrote:
> 
> On Wed, Jul 04, 2018 at 09:03:15AM +0100, Phil Thompson wrote:
>> On 3 Jul 2018, at 11:09 pm, Phil Thompson <phil at riverbankcomputing.com> wrote:
>>> 
>>> On 3 Jul 2018, at 9:54 pm, Dmitry Shachnev <mitya57 at ubuntu.com> wrote:
>>>> 
>>>> On Tue, Jul 03, 2018 at 12:31:55PM +0100, Phil Thompson wrote:
>>>>>> 2) With these releases, I am seeing PyQt5 import failures with Python 3.5
>>>>>> on Windows:
>>>>>> 
>>>>>> https://ci.appveyor.com/project/mitya57/retext/build/1.0.217/job/tyw6ceps2o925eq9
>>>>>> 
>>>>>> File "c:\projects\retext\ReText\__init__.py", line 24, in <module>
>>>>>> from PyQt5.QtCore import QByteArray, QLocale, QSettings, QStandardPaths
>>>>>> ImportError: DLL load failed: The specified procedure could not be found.
>>>>>> 
>>>>>> Do you know what could cause this?
>>>>> 
>>>>> I can't reproduce it (Windows 10, 64-bit, Python v3.5.4).
>>>> 
>>>> Apparently AppVeyor has Python v3.5.3, so probably that was the issue.
>>>> 
>>>> I will just drop 3.5 from my CI config.
>>> 
>>> The Python minor version shouldn't make any difference.
>> 
>> ...but it does. I think the problem is with this...
>> 
>> https://docs.python.org/3/c-api/slice.html#c.PySlice_GetIndicesEx
>> 
>> I think this affects Python v3.5.0-3 and v3.6.0.
> 
> I just got a similar report with Python 3.5.1-3 (on Ubuntu 16.04):
> 
>    from PyQt5 import QtCore
> ImportError: .../python3.5/site-packages/PyQt5/QtCore.so: undefined symbol: PySlice_AdjustIndices
> 
> Note that this seems to be about PySlice_AdjustIndices and not
> PySlice_GetIndicesEx.
> 
> The documentation says that was added in 3.6.1:
> https://docs.python.org/3/c-api/slice.html#c.PySlice_AdjustIndices

In later versions PySlice_GetIndicesEx is implemented using PySlice_AdjustIndices. The problem is that the use of the limited API seems broken to me - it doesn't seem possible to create a binary built with (say) 3.7 to work against all versions of 3.6 and 3.5.

It's easy enough for me to work around but (as it affects old versions of Python) I wont release a new version just for that.

Phil


More information about the PyQt mailing list