pip install pymysql
more info here : http://stackoverflow.com/questions/34777755/how-to-
config-django-using-pymysql-as-driver
--
Ticket URL: <https://code.djangoproject.com/ticket/28145>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.
Comment (by Tim Graham):
We're recommending the
[https://docs.djangoproject.com/en/dev/ref/databases/#mysql-db-api-drivers
mysqlclient] MySQLdb fork. Is there a reason to prefer PyMySQL instead?
--
Ticket URL: <https://code.djangoproject.com/ticket/28145#comment:1>
* status: new => closed
* resolution: => needsinfo
--
Ticket URL: <https://code.djangoproject.com/ticket/28145#comment:2>
Comment (by pojda):
Jumping into something old here, but I have to add some info: the
mysqlclient lib you recommend is a pain to install on Mac or Windows,
while **PyMysql works out of the box**.
I had to use the same workaround mentioned on that stackoverflow post -
which I don't like because I'm modifying Django's source and may cause
trouble when upgrading.
Cheers!
--
Ticket URL: <https://code.djangoproject.com/ticket/28145#comment:3>
* cc: Sergey Fedoseev (added)
Comment:
Replying to [comment:3 pojda]:
> I had to use the same workaround mentioned on that stackoverflow post -
which I don't like because I'm modifying Django's source and may cause
trouble when upgrading.
It looks like this workaround can be added to `settings.py` as well:
https://stackoverflow.com/questions/34777755/how-to-config-django-using-
pymysql-as-driver#comment92469445_34778155
--
Ticket URL: <https://code.djangoproject.com/ticket/28145#comment:4>
Comment (by andreymal):
Replying to [comment:1 Tim Graham]:
> Is there a reason to prefer PyMySQL instead?
There is a very important reason: mysqlclient is GPL-licensed. This makes
it impossible to create proprietary projects using MySQL. (I know it's not
AGPL and I'm not obliged to publish my backend code for everyone, but GPL
may still have other legal problems.)
In fact, I would really like the PyMySQL support to be full and official.
--
Ticket URL: <https://code.djangoproject.com/ticket/28145#comment:5>