django-model-utils icon indicating copy to clipboard operation
django-model-utils copied to clipboard

FieldTracker for AbstractModel children is still not stable

Open Atorich opened this issue 6 years ago • 5 comments

Problem

I have found that AbstractModelTrackerTests is not quite correct. Since it inherited from FieldTrackerTestCase that just implements some extra assertions, there are no actual tests for this case.

Solution

I have fixed AbstractModelTrackerTests and it seems that some tests are failed for the case with models inherited from some AbstractModel with fields defined (like AbstractUser and its children)

#381 - pull request

Atorich avatar Aug 05 '19 12:08 Atorich

I can confirm that models that inherit from an abstract base model (like AbstractBaseUser) no longer seem to update correctly since upgrading to v3.2.0.

Like the failing tests demonstrate, changing one of the model's fields does not actually change the value stored in that field.

jcass77 avatar Aug 14 '19 11:08 jcass77

Thank you @Atorich for finding out about this. @jcass77 do you feel like having some bandwidth to start a PR about this?

Natim avatar Aug 20 '19 13:08 Natim

#370 and #331 are related

Atorich avatar Aug 20 '19 13:08 Atorich

@Natim has indicated that this is blocked upstream in Django by #30427.

jcass77 avatar Aug 21 '19 16:08 jcass77

Would someone update me/us on the status of this? The last activity (other than bumping the versions) seems to be:

  • it was noted that "this is blocked upstream in Django by #30427"
  • Then #30427 (and #16176) were fixed.

Does that mean this issue is unblocked? Is there a fix in the works?

ExTexan avatar Jun 14 '21 14:06 ExTexan