MySQL backend schema editor skip_default method requires update for MySQL 5.7
Currently this method, django.db.backends.mysql.schema.DatabaseSchemaEditor.skip_default, checks for a certain group of field types (texts and blobs) to determine whether defaults are applicable at the database level. Since MySQL 5.7, there is one more which I believe needs to be added to this list - the new 'json' type. I discovered this while working with the django-mysql module. In that module a default of dict
is set at the Django model level but needs to be ignored for database operations.
As far as I can see it should be a pretty straight forward fix as I can't see why it would interfere with the functionality for older versions of MySQL.
Change History
(5)
Triage Stage: |
Unreviewed → Accepted
|
Triage Stage: |
Accepted → Ready for checkin
|
Resolution: |
→ fixed
|
Status: |
new → closed
|
PR: https://github.com/django/django/pull/6997