0

I have debian-box and when i run the following command for install python module, i get error, my command:

pip3 install mysql-python

My error:

Downloading/unpacking mysql-python
  Downloading MySQL-python-1.2.4.zip (113kB): 113kB downloaded
  Running setup.py egg_info for package mysql-python
    Traceback (most recent call last):
      File "<string>", line 16, in <module>
      File "/tmp/pip_build_root/mysql-python/setup.py", line 14, in <module>
        from setup_posix import get_config
      File "./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 16, in <module>

  File "/tmp/pip_build_root/mysql-python/setup.py", line 14, in <module>

    from setup_posix import get_config

  File "./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 complete log in /root/.pip/pip.log

Question: Where's my problem?

PersianGulf
  • 2,845
  • 6
  • 47
  • 67
  • Python 3 isn't supported by mysql-python. – Blender Aug 24 '13 at 06:25
  • So, how can i use `SQLAlchey` in `python3`? It's needed ....! – PersianGulf Aug 24 '13 at 06:50
  • Where can i rename `ConfigParser` to `configparser`? – PersianGulf Aug 24 '13 at 06:53
  • renaming `ConfigParser` will not fix the problem. You should use [mysql-connector-python](https://pypi.python.org/pypi/mysql-connector-python) or [PyMySQL3](https://pypi.python.org/pypi/PyMySQL3) as replacement. See also [here](http://docs.sqlalchemy.org/en/rel_0_8/dialects/mysql.html). – mata Aug 24 '13 at 07:32

0 Answers0