Python3.4 can't install mysql-python
19,970
Solution 1
Resolved:
pip3.4 install --allow-external mysql-connector-python
Edit settings.py
'ENGINE': 'mysql.connector.django',
Solution 2
MySQL-python 1.2.5 does not support Python 3. The Django 1.7 docs recommend the fork mysqlclient.
Author by
Ruslan
Updated on July 23, 2022Comments
-
Ruslan almost 2 years
# pip3.4 install mysql-python Downloading/unpacking mysql-python Downloading MySQL-python-1.2.5.zip (108kB): 108kB downloaded Running setup.py (path:/tmp/pip_build_root/mysql-python/setup.py) egg_info for package mysql-python Traceback (most recent call last): File "<string>", line 17, in <module> File "/tmp/pip_build_root/mysql-python/setup.py", line 13, in <module> from setup_posix import get_config File "/tmp/pip_build_root/mysql-python/setup_posix.py", line 2, in <module> from ConfigParser import SafeConfigParser ImportError: No module named 'ConfigParser' Complete output from command python setup.py egg_info: Traceback (most recent call last): File "<string>", line 17, in <module> File "/tmp/pip_build_root/mysql-python/setup.py", line 13, in <module> from setup_posix import get_config File "/tmp/pip_build_root/mysql-python/setup_posix.py", line 2, in <module> from ConfigParser import SafeConfigParser ImportError: No module named 'ConfigParser' ---------------------------------------- Cleaning up... Command python setup.py egg_info failed with error code 1 in /tmp/pip_build_root/mysql-python Storing debug log for failure in /root/.pip/pip.log
-
Alasdair over 8 yearsI've seen questions from users struggling to get MySQL connector to work. The Django docs recommend mysqlclient.
-
nicks almost 8 yearswhere you able to install
mysql-python
after that? -
Haifeng Zhang over 7 yearsthis answer doesnt help me. the answer posted by Alasdair below helped.
-
Himanshu Bansal over 6 yearsDEPRECATION: --allow-external has been deprecated and will be removed in the future. Due to changes in the repository pr otocol, it no longer has any effect.