[PyQt] Qt classes not available
Glenn Ramsey
gr at componic.co.nz
Mon Nov 19 20:37:04 GMT 2018
Hi Phil,
On 17/11/18 5:56 AM, Phil Thompson wrote:
> On 16 Nov 2018, at 3:59 am, Glenn Ramsey <gr at componic.co.nz> wrote:
>>
>> Hi,
>>
>> I have built PyQt5 (PyQt5_commercial-5.12.dev1810261601 or
>> PyQt5_commercial-5.11.3) against a development version of Qt 5.12 from git and
>> Python 2.7.15 on Windows10 using VS2017. I've tried sip 4.19.13 and
>> sip-4.19.14.dev1810291324. Building and installing appears to have completed
>> without errors.
>>
>> PyQt doesn't seem to be wrapping the Qt objects as they do not appear to be
>> available in the PyQt5 namespace as shown in the following output:
>>
>>
>> Any ideas why this might be? I've been following this build process for years
>> and never had an issue like this before.
>
> Then you probably need to update your build process...
>
> https://pyqt.readthedocs.io/en/latest/installation.html#downloading-sip
> http://pyqt.sourceforge.net/Docs/sip4/using.html#ref-private-sip
Configuring using the necessary --sip-module parameter fixed it, thanks:
python configure.py --sip-module PyQt5.sip --no-tools
Knowing what I was looking for I was unable to find any mention of this in the
downloaded distributions for either PyQt5 or sip and would never have thought to
look on readthedocs.io.
I think it would be worth noting this in the README or NEWS files. However even
if it was there I probably wouldn't have found it, so perhaps it would be useful
to have a message appear on the console after configure.py has run to highlight
this change? E.g. " we notice you're using PyQt 5.11 but haven't used the
--sip-module flag - see <link to docs>"
Glenn
More information about the PyQt
mailing list