I’m preparing my project for the 4.0 release and came up with an issue that I’m not sure how to address.
I have models that use a
JSONField. Nowadays, they use Django’s builtin
JSONField but before that, they were using the implementation from
django-jsonfield (which is now unmaintained).
As a consequence, my migration files still reference
My issue is that I’m getting some deprecation warnings when running with
/path/to/venv/jsonfield/fields.py:22: RemovedInDjango40Warning: django.utils.translation.ugettext_lazy() is deprecated in favor of django.utils.translation.gettext_lazy().
As mentionned above,
django-jsonfield is (understandably) unmaintained and its repository on github is archived/readonly so I can’t file a bug report.
So how would you approach this? Should I maintain a fork of
django-jsonfield so i can keep referencing it in my migrations? Should I try to reset my migration files (delete all of them and start with a fresh
makemigrations)? Edit the problematic migration files by hand to replace the reference to the old
JSONField with some kind of simplified fake object? Maybe another option?