Re: [Django] #34319: Model.validate_constraints() crashes when constraint's validate() raises ValidationError without a code.

9 views
Skip to first unread message

Django

unread,
Feb 8, 2023, 2:15:43 AM2/8/23
to django-...@googlegroups.com
#34319: Model.validate_constraints() crashes when constraint's validate() raises
ValidationError without a code.
-------------------------------------+-------------------------------------
Reporter: Mateusz Kurowski | Owner: Mariusz
| Felisiak
Type: Bug | Status: assigned
Component: Database layer | Version: 4.1
(models, ORM) |
Severity: Release blocker | Resolution:
Keywords: Model, | Triage Stage: Accepted
validate_constraints, |
ValidationError, code, message |
Has patch: 0 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
-------------------------------------+-------------------------------------
Changes (by Mariusz Felisiak):

* owner: nobody => Mariusz Felisiak
* status: new => assigned


--
Ticket URL: <https://code.djangoproject.com/ticket/34319#comment:6>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.

Django

unread,
Feb 8, 2023, 2:28:22 AM2/8/23
to django-...@googlegroups.com
#34319: Model.validate_constraints() crashes when constraint's validate() raises
ValidationError without a code.
-------------------------------------+-------------------------------------
Reporter: Mateusz Kurowski | Owner: Mariusz
| Felisiak
Type: Bug | Status: assigned
Component: Database layer | Version: 4.1
(models, ORM) |
Severity: Release blocker | Resolution:
Keywords: Model, | Triage Stage: Accepted
validate_constraints, |
ValidationError, code, message |
Has patch: 1 | Needs documentation: 0

Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
-------------------------------------+-------------------------------------
Changes (by Mariusz Felisiak):

* has_patch: 0 => 1


Comment:

[https://github.com/django/django/pull/16533 PR]

--
Ticket URL: <https://code.djangoproject.com/ticket/34319#comment:7>

Django

unread,
Feb 8, 2023, 2:49:56 AM2/8/23
to django-...@googlegroups.com
#34319: Model.validate_constraints() crashes when constraint's validate() raises
ValidationError without a code.
-------------------------------------+-------------------------------------
Reporter: Mateusz Kurowski | Owner: Mariusz
| Felisiak
Type: Bug | Status: assigned
Component: Database layer | Version: 4.1
(models, ORM) |
Severity: Release blocker | Resolution:
Keywords: Model, | Triage Stage: Ready for
validate_constraints, | checkin

ValidationError, code, message |
Has patch: 1 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
-------------------------------------+-------------------------------------
Changes (by Carlton Gibson):

* stage: Accepted => Ready for checkin


--
Ticket URL: <https://code.djangoproject.com/ticket/34319#comment:8>

Django

unread,
Feb 8, 2023, 10:39:16 AM2/8/23
to django-...@googlegroups.com
#34319: Model.validate_constraints() crashes when constraint's validate() raises
ValidationError without a code.
-------------------------------------+-------------------------------------
Reporter: Mateusz Kurowski | Owner: Mariusz
| Felisiak
Type: Bug | Status: closed

Component: Database layer | Version: 4.1
(models, ORM) |
Severity: Release blocker | Resolution: fixed

Keywords: Model, | Triage Stage: Ready for
validate_constraints, | checkin
ValidationError, code, message |
Has patch: 1 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
-------------------------------------+-------------------------------------
Changes (by GitHub <noreply@…>):

* status: assigned => closed
* resolution: => fixed


Comment:

In [changeset:"2fd755b361d3da2cd0440fc9839feb2bb69b027b" 2fd755b3]:
{{{
#!CommitTicketReference repository=""
revision="2fd755b361d3da2cd0440fc9839feb2bb69b027b"
Fixed #34319 -- Fixed Model.validate_constraints() crash on
ValidationError with no code.

Thanks Mateusz Kurowski for the report.

Regression in 667105877e6723c6985399803a364848891513cc.
}}}

--
Ticket URL: <https://code.djangoproject.com/ticket/34319#comment:9>

Django

unread,
Feb 8, 2023, 10:40:35 AM2/8/23
to django-...@googlegroups.com
#34319: Model.validate_constraints() crashes when constraint's validate() raises
ValidationError without a code.
-------------------------------------+-------------------------------------
Reporter: Mateusz Kurowski | Owner: Mariusz
| Felisiak
Type: Bug | Status: closed
Component: Database layer | Version: 4.1
(models, ORM) |
Severity: Release blocker | Resolution: fixed
Keywords: Model, | Triage Stage: Ready for
validate_constraints, | checkin
ValidationError, code, message |
Has patch: 1 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
-------------------------------------+-------------------------------------

Comment (by Mariusz Felisiak <felisiak.mariusz@…>):

In [changeset:"836ae73a8962876a3beb98bc711fa397d700c82f" 836ae73]:
{{{
#!CommitTicketReference repository=""
revision="836ae73a8962876a3beb98bc711fa397d700c82f"
[4.2.x] Fixed #34319 -- Fixed Model.validate_constraints() crash on
ValidationError with no code.

Thanks Mateusz Kurowski for the report.

Regression in 667105877e6723c6985399803a364848891513cc.
Backport of 2fd755b361d3da2cd0440fc9839feb2bb69b027b from main
}}}

--
Ticket URL: <https://code.djangoproject.com/ticket/34319#comment:10>

Django

unread,
Feb 8, 2023, 10:41:03 AM2/8/23
to django-...@googlegroups.com
#34319: Model.validate_constraints() crashes when constraint's validate() raises
ValidationError without a code.
-------------------------------------+-------------------------------------
Reporter: Mateusz Kurowski | Owner: Mariusz
| Felisiak
Type: Bug | Status: closed
Component: Database layer | Version: 4.1
(models, ORM) |
Severity: Release blocker | Resolution: fixed
Keywords: Model, | Triage Stage: Ready for
validate_constraints, | checkin
ValidationError, code, message |
Has patch: 1 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
-------------------------------------+-------------------------------------

Comment (by Mariusz Felisiak <felisiak.mariusz@…>):

In [changeset:"590a92e4562c8ebd3eb25dc1e878bd1e3eb758d4" 590a92e4]:
{{{
#!CommitTicketReference repository=""
revision="590a92e4562c8ebd3eb25dc1e878bd1e3eb758d4"
[4.1.x] Fixed #34319 -- Fixed Model.validate_constraints() crash on
ValidationError with no code.

Thanks Mateusz Kurowski for the report.

Regression in 667105877e6723c6985399803a364848891513cc.
Backport of 2fd755b361d3da2cd0440fc9839feb2bb69b027b from main
}}}

--
Ticket URL: <https://code.djangoproject.com/ticket/34319#comment:11>

Reply all
Reply to author
Forward
0 new messages