[PyQt] QMySql driver for PyQt 5.7

Nekhelesh Ramananthan krnekhelesh at gmail.com
Thu Mar 9 14:39:59 GMT 2017


>
>
> The PyQt wheels include their own copy of Qt so installing something for
> the system Qt isn't going to make any difference. Why not use the latest
> wheels?
>
> Phil
>

At first I was hesitant to use the latest PyQt5 version 5.8.1 as I would
need time to ensure that nothing broke in my app. However I decided to
upgrade and still face the issue with PyQt 5.8.1. One of the other things I
found during google search was to do "ldd
~/.local/lib/python3.5/site-packages/PyQt5/Qt/plugins/sqldrivers/libqsqlmysql.so"
and check if all dependencies are satisfied. However with PyQt 5.7 I got
the following output,

        linux-vdso.so.1 =>  (0x00007ffd351de000)
libmysqlclient_r.so.16 => not found
libz.so.1 => /lib/x86_64-linux-gnu/libz.so.1 (0x00007fb788ad7000)
libcrypt.so.1 => /lib/x86_64-linux-gnu/libcrypt.so.1 (0x00007fb78889e000)
libnsl.so.1 => /lib/x86_64-linux-gnu/libnsl.so.1 (0x00007fb788685000)
libssl.so.10 => not found
libcrypto.so.10 => not found
libQt5Sql.so.5 =>
/home/krnekhelesh/.local/lib/python3.5/site-packages/PyQt5/Qt/plugins/sqldrivers/./../../lib/libQt5Sql.so.5
(0x00007fb78843f000)
libQt5Core.so.5 =>
/home/krnekhelesh/.local/lib/python3.5/site-packages/PyQt5/Qt/plugins/sqldrivers/./../../lib/libQt5Core.so.5
(0x00007fb787d23000)
libpthread.so.0 => /lib/x86_64-linux-gnu/libpthread.so.0
(0x00007fb787b06000)
libstdc++.so.6 => /usr/lib/x86_64-linux-gnu/libstdc++.so.6
(0x00007fb787784000)
libm.so.6 => /lib/x86_64-linux-gnu/libm.so.6 (0x00007fb78747b000)
libgcc_s.so.1 => /lib/x86_64-linux-gnu/libgcc_s.so.1 (0x00007fb787264000)
libc.so.6 => /lib/x86_64-linux-gnu/libc.so.6 (0x00007fb786e9b000)
libicui18n.so.56 =>
/home/krnekhelesh/.local/lib/python3.5/site-packages/PyQt5/Qt/plugins/sqldrivers/./../../lib/libicui18n.so.56
(0x00007fb786a00000)
libicuuc.so.56 =>
/home/krnekhelesh/.local/lib/python3.5/site-packages/PyQt5/Qt/plugins/sqldrivers/./../../lib/libicuuc.so.56
(0x00007fb786648000)
libicudata.so.56 =>
/home/krnekhelesh/.local/lib/python3.5/site-packages/PyQt5/Qt/plugins/sqldrivers/./../../lib/libicudata.so.56
(0x00007fb784c65000)
libdl.so.2 => /lib/x86_64-linux-gnu/libdl.so.2 (0x00007fb784a60000)
libgthread-2.0.so.0 => /usr/lib/x86_64-linux-gnu/libgthread-2.0.so.0
(0x00007fb78485e000)
librt.so.1 => /lib/x86_64-linux-gnu/librt.so.1 (0x00007fb784656000)
libglib-2.0.so.0 => /lib/x86_64-linux-gnu/libglib-2.0.so.0
(0x00007fb784344000)
/lib64/ld-linux-x86-64.so.2 (0x000056360010a000)
libpcre.so.3 => /lib/x86_64-linux-gnu/libpcre.so.3 (0x00007fb7840d4000)

The libmysqlclient_r.so.16, libssl.so.10 and libcrypto.so.10 are not found.
I suspect that could be the issue why PyQt5 detects that the mysql driver
is present, but cannot load it. Ubuntu 16.04 doesn't ship with those
versions. Instead I could only find libmysqlclient.so.20.

If anyone is on Ubuntu (amd64), can you attach those 3 missing library
files? I can check if that resolves the issue. Although I am not sure how
to ensure this issue doesn't occur on systems that I deploy my app to.

Kind regards,
Nekhelesh
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://www.riverbankcomputing.com/pipermail/pyqt/attachments/20170309/2fdf6e05/attachment.html>


More information about the PyQt mailing list