I have tried a few different ways to get this installed. mysqlclient and also tried pip install MySQL-python both result in error.
pi@raspberrypi:/ $ pip install MySQL-python
Looking in indexes: https://pypi.org/simple, https://www.piwheels.org/simple
Collecting MySQL-python
Using cached https://files.pythonhosted.org/packages/a5/e9/51b544da85a36a68debe7a7091f068d802fc515a3a202652828c73453cad/MySQL-python-1.2.5.zip
Complete output from command python setup.py egg_info:
sh: 1: mysql_config: not found
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "/tmp/pip-install-YvczBg/MySQL-python/setup.py", line 17, in <module>
metadata, options = get_config()
File "setup_posix.py", line 43, in get_config
libs = mysql_config("libs_r")
File "setup_posix.py", line 25, in mysql_config
raise EnvironmentError("%s not found" % (mysql_config.path,))
EnvironmentError: mysql_config not found
----------------------------------------
Command "python setup.py egg_info" failed with error code 1 in /tmp/pip-install-YvczBg/MySQL-python/
pi@raspberrypi:/ $ pip install MySQLclient
Looking in indexes: https://pypi.org/simple, https://www.piwheels.org/simple
Collecting MySQLclient
Downloading https://files.pythonhosted.org/packages/d0/97/7326248ac8d5049968bf4ec708a5d3d4806e412a42e74160d7f266a3e03a/mysqlclient-1.4.6.tar.gz (85kB)
100% |████████████████████████████████| 92kB 1.3MB/s
Complete output from command python setup.py egg_info:
sh: 1: mysql_config: not found
sh: 1: mariadb_config: not found
sh: 1: mysql_config: not found
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "/tmp/pip-install-n01LjQ/MySQLclient/setup.py", line 16, in <module>
metadata, options = get_config()
File "setup_posix.py", line 61, in get_config
libs = mysql_config("libs")
File "setup_posix.py", line 29, in mysql_config
raise EnvironmentError("%s not found" % (_mysql_config_path,))
EnvironmentError: mysql_config not found
----------------------------------------
Command "python setup.py egg_info" failed with error code 1 in /tmp/pip-install-n01LjQ/MySQLclient/
pi@raspberrypi:/ $
Is something wrong with my install on rasbian buster?
This worked last week for 10 other Pis i have. But this week I cannot get anything to install. I tested my pip3 to see if it was a bad pip install but that works for other installs. for whatever reason I cannot get mysqlclients to install. Any ideas?
What I have tried
- I have uninstalled and reinstalled python 1,2,3
- I have reinstalled Buster I have pulled my hair out! lol
- I have also used pip3 install mysqlclient and same results.
- I have used sudo pip3 install but same results
I have also tried installing from rasbian repository
pi@raspberrypi:/ $ sudo apt-get install mysqlclient
Reading package lists... Done
Building dependency tree
Reading state information... Done
E: Unable to locate package mysqlclient
pi@raspberrypi:/ $ sudo apt-get install MySQL-python
Reading package lists... Done
Building dependency tree
Reading state information... Done
E: Unable to locate package MySQL-python