[PyQt] PyQt4 Support for Multiple APIs

Dmitry Shachnev mitya57 at ubuntu.com
Sat Jan 30 18:28:04 GMT 2016


Hi Phil,

On Sat, Jan 30, 2016 at 06:15:46PM +0000, Phil Thompson wrote:
> As you probably know, PyQt4 supports multiple, incompatible APIs...
>
> http://pyqt.sourceforge.net/Docs/PyQt4/incompatible_apis.html
>
> The old APIs were the default for Python v2 and the new ones the default for
> Python v3.
>
> The feature was added to aid in the porting of applications from Python v2
> to Python v3. It was never intended that production code should make use of
> it - although I doubt I ever made that as explicit as I should have. For
> example, all the packages used by an application must agree to use the same
> APIs, which makes using third-party code problematic.
>
> With hindsight it's something I wish I'd never implemented. The code to
> support it is complex and is unlikely to be used again in the future - so it
> will probably not get tested properly. Consequently I'm considering dropping
> the support in SIP v4.18 and PyQt v4.12.
>
> Please let me know if you are switching to the later APIs in your Python v2
> code. Hopefully nobody is, but maybe everybody is...

Do I understand it correctly that you want to completely remove the sip.setapi
method?

There *is* code that uses sip.setapi in production — around 39 packages in
Debian according to our codesearch [1].

[1]: https://codesearch.debian.net/results/sip.setapi/page_0
     (a big part of the results are sip4/python-qt4 themselves, to get results
     for other packages click on their names in the list on page top)

--
Dmitry Shachnev
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: not available
URL: <https://www.riverbankcomputing.com/pipermail/pyqt/attachments/20160130/2090fe6b/attachment.sig>


More information about the PyQt mailing list