Changes between Version 2 and Version 3 of Ticket #35575


Ignore:
Timestamp:
Jul 3, 2024, 6:32:47 AM (3 months ago)
Author:
Mark Gensler
Comment:

Legend:

Unmodified
Added
Removed
Modified
  • Ticket #35575 – Description

    v2 v3  
    1 `GeneratedField`s on a model instance are not recalculated during `Model.full_clean()`. Therefore, if a `GeneratedField` is included in the `*expressions` or `fields` parameters of a `UniqueConstraint` or `CheckConstraint` in the instance's `Model._meta`, the new values of the `GeneratedField` attribute are not uaed by `BaseConstraint.validate()`.
     1`GeneratedField`s on a model instance are not recalculated during `Model.full_clean()`. Therefore, if a `GeneratedField` is included in the `*expressions` or `fields` parameters of a `UniqueConstraint` or `CheckConstraint` in the instance's `Model._meta`, the new values of the `GeneratedField` attribute are not used by `BaseConstraint.validate()`.
    22
    33Instead, the model instance's `GeneratedField` attribute will return the value which corresponds to the most recent refresh of the instance from the database. If the instance is new and has not yet been saved, the following error is raised:
Back to Top