[openstack-dev] [all] Replace mysql-python with mysqlclient

Victor Stinner vstinner at redhat.com
Mon May 4 09:43:32 UTC 2015


Hi,

Mike Bayer wrote:
> It is not feasible to use MySQLclient in Python 2 because it uses the
> same module name as Python-MySQL, and would wreak havoc with distro
> packaging and many other things.

IMO mysqlclient is just the new upstream for MySQL-Python, since MySQL-Python is no more maintained.

Why Linux distributions would not package mysqlclient if it provides Python 3 support, contains bugfixes and more features?

It's quite common to have two packages in conflicts beceause they provide the same function, same library, same program, etc.

I would even suggest packagers to use mysqlclient as the new source without modifying their package.


> It is also imprudent to switch
> production openstack applications to a driver that is new and untested
> (even though it is a port), nor is it necessary.

Why do you consider that mysqlclient is not tested or less tested than mysql-python? Which kind of regression do you expect in mysqlclient?

As mysql-python, mysqlclient Github project is connected to Travis:
https://travis-ci.org/PyMySQL/mysqlclient-python
(tests pass)

I trust more a project which is actively developed.


> There should be no
> reason Openstack applications are hardcoded to one database driver.
> The approach should be simply that in Python 3, the mysqlclient library
> is installed instead of mysql-python.

Technically, it's now possible to have different dependencies on Python 2 and Python 3. But in practice, there are some annoying corner cases. It's more convinient to have same dependencies on Python 2 and Python 3.

Using mysqlclient on Python 2 and Python 3 would avoid to have bugs specific to Python 2 (bugs already fixed in mysqlclient) and new features only available on Python 3.

Victor



More information about the OpenStack-dev mailing list