Description:
There seems to be some confusion as to the name of the package as reported by pip. One can install the package referring to it as 'mysql-connector'. Once installed however it is referred to as 'mysql-connector-python'. This inconsistency causes issues for anything looking for the former but finding the latter: in our case this breaks Puppet behaviour as Puppet reinstalls the package over and over again...
How to repeat:
[root@host tmp]# pip search mysql | grep -i ^mysql-connector
mysql-connector-repackaged - MySQL driver written in Python
MySQL-Connector - MySQL driver within in Python
[root@host tmp]# pip install mysql-connector
Downloading/unpacking mysql-connector
Downloading mysql-connector-python-0.3.2-devel.tar.gz (129Kb): 129Kb downloaded
Running setup.py egg_info for package mysql-connector
Installing collected packages: mysql-connector
Running setup.py install for mysql-connector
Successfully installed mysql-connector
Cleaning up...
[root@host tmp]# pip freeze | grep mysql
mysql-connector-python==0.3.2-devel
[root@host tmp]# pip uninstall mysql-connector
Cannot uninstall requirement mysql-connector, not installed
Storing complete log in /root/.pip/pip.log
[root@host tmp]# pip install mysql-connector-python
Requirement already satisfied (use --upgrade to upgrade): mysql-connector-python in /usr/lib/python2.6/site-packages
Cleaning up...
[root@host tmp]# pip uninstall mysql-connector-python
Uninstalling mysql-connector-python:
/usr/lib/python2.6/site-packages/mysql
/usr/lib/python2.6/site-packages/mysql_connector_python-0.3.2_devel-py2.6.egg-info
Proceed (y/n)? y
Successfully uninstalled mysql-connector-python
[root@host tmp]# pip install mysql-connector-python
Downloading/unpacking mysql-connector-python
Could not find any downloads that satisfy the requirement mysql-connector-python
No distributions at all found for mysql-connector-python
Storing complete log in /root/.pip/pip.log
Suggested fix:
The name should be consistent, though which is the correct one I have no idea :)