#14219 closed (duplicate)
Incorrect empty field validation for DateTimeField with SplitDateTimeWidget
| Reported by: | pma_ | Owned by: | nobody |
|---|---|---|---|
| Component: | Forms | Version: | 1.1 |
| Severity: | Keywords: | validation DateTimeField | |
| Cc: | Triage Stage: | Unreviewed | |
| Has patch: | no | Needs documentation: | no |
| Needs tests: | no | Patch needs improvement: | no |
| Easy pickings: | no | UI/UX: | no |
Description
Create simple form with field like dt = DateTimeField(widget=SplitDateTimeWidget)
clean will report error, source is in first line of DateTimeField.to_python
in case of SplitDateTimeWidget value is [, ] and this one is missing from validators.EMPTY_VALUES.
I'm not sure if it's safe to simply path validators.EMPTY_VALUES by adding [,] to list
Note:
See TracTickets
for help on using tickets.
I think this is the same as #13205