I just upgraded my Ubuntu install to 16.04 and this seems to have broken my mysql dependencies in the MySQL-python package.
Here is my error message:
I ended up finding the solution to my problems with pip install --no-binary MySQL-python MySQL-python
as stated in this thread : Python's MySQLdb can’t find libmysqlclient.dylib with Homebrewed MySQL
Thank for Largaroth. If you use mysqlclient
on Ubuntu 16.04 and have error:
ImportError: libmysqlclient.so.18: cannot open shared object file: No such file or directory
You can fix:
sudo -H pip uninstall mysqlclient
sudo -H pip install --no-binary mysqlclient mysqlclient
I had the same issue. I uninstalled and reinstalled MySQL-python:
pip uninstall MySQL-python
pip install MySQL-python
I had this issue with python 3.6... when I used an environment with Python 3.5 it worked just fine.
I solved this on my virtual environment using django 2.2.7 and Ubuntu 19.10 by doing:
pip3 uninstall mysqlclient
pip3 install mysqlclient
I had this issue on updating to stretch. To fix it I updated my requirements.txt:
mysqlclient==1.4.2.post1
So either update that manually or pip install --upgrade mysqlclient