Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Tracker field and Django 3.2 #514

Open
brianmay opened this issue Dec 12, 2021 · 0 comments
Open

Tracker field and Django 3.2 #514

brianmay opened this issue Dec 12, 2021 · 0 comments

Comments

@brianmay
Copy link

Problem

I want to be able to upgrade my application to Django 3.2.

But I was forced to stay behind and use an old version of django-model-utils (3.1.2), because the TrackerField has been broken. I think this might be:

#331

But this old version of django-model-utils breaks with Django 3.2:

E                   AttributeError: 'DeferredAttribute' object has no attribute 'field_name'

/home/brian/.cache/pypoetry/virtualenvs/karaage-uhi1oUwy-py3.9/lib/python3.9/site-packages/model_utils/tracker.py:112: AttributeError

So I need to upgrade django-model-utils. Fair enough. But it breaks due to the previous issue:

#469

Apparently Django 4.0 would fix this (?), but:

  • Recommended Django upgrade practise is that I upgrade to 3.2 release first.
  • Django 4.0 breaks a number of 3rd party packages that we use, don't particularly want to have to round up and fix all of these.
  • I actually do want the LTS release of Django.

So what is the solution? Is there any solution to get this working with Django 3.2? Maybe by patching the old version?

Or maybe I need to migrate/rewrite my code not to use TrackerField?

Environment

  • Django Model Utils version: 3.1.2/4.2 as discussed
  • Django version: 3.2
  • Python version: 3.9
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant