#25777 closed New feature (wontfix)
Django admin/views don't expect forms to fail after validation
| Reported by: | Vlastimil Zíma | Owned by: | nobody |
|---|---|---|---|
| Component: | Forms | Version: | 1.8 |
| Severity: | Normal | Keywords: | |
| Cc: | Triage Stage: | Unreviewed | |
| Has patch: | no | Needs documentation: | no |
| Needs tests: | no | Patch needs improvement: | no |
| Easy pickings: | no | UI/UX: | no |
Description
Django assumes that all input data in forms can be validated by Form.is_valid() which is not true. Database contraints, e.g. unique, can fail even though they are checked. An application may require communication with other servers while processing data which can lead to errors.
Both Django admin and generic form views should expect that save may fail despite the validation and provide a way to handle those errors easily, e.g. expect ValidationError can be raised by Model.save and ModelForm.save etc.
Change History (2)
comment:1 by , 10 years ago
| Resolution: | → wontfix |
|---|---|
| Status: | new → closed |
comment:2 by , 9 years ago
| Component: | Uncategorized → Forms |
|---|---|
| Type: | Uncategorized → New feature |
Note:
See TracTickets
for help on using tickets.
This would be a fundamental change in the design of Django and should first be discussed on the DevelopersMailingList to find a consensus. Thanks!