Changes between Version 2 and Version 3 of Ticket #34293, comment 5


Ignore:
Timestamp:
Jan 25, 2023, 8:22:47 PM (20 months ago)
Author:
Simon Charette

Legend:

Unmodified
Added
Removed
Modified
  • Ticket #34293, comment 5

    v2 v3  
    11I think I understand what's going on here.
    22
    3 The reporter defined constraints in a way makes assumption that `schedule_start_lt_end` will always be enforced before `schedule_exclude_overlapping` is which depends on the order of creation of constraints on the table and the order of the members of `Meta.constraints`.
     3The reporter defined constraints in a way that assumes `schedule_start_lt_end` will always be enforced before `schedule_exclude_overlapping` is which depends on the order of creation of constraints on the table and the order of the members of `Meta.constraints`.
    44
    55I think this might be an argument to make `Model.validate_constraint` abort on the first `ValidationError` it encounters. The alternative solution would be document that ''dependent'' constraints should use `conditions` so they can be skipped on invalid input.
Back to Top