[Django] #25065: Should EmailField empty_strings_allowed be False

10 views
Skip to first unread message

Django

unread,
Jul 5, 2015, 10:30:55 PM7/5/15
to django-...@googlegroups.com
#25065: Should EmailField empty_strings_allowed be False
----------------------------------------------+--------------------
Reporter: CrazyCasta | Owner: nobody
Type: Uncategorized | Status: new
Component: Database layer (models, ORM) | Version: 1.8
Severity: Normal | Keywords:
Triage Stage: Unreviewed | Has patch: 0
Easy pickings: 0 | UI/UX: 0
----------------------------------------------+--------------------
Sorry for stating this as a question, I'm a little new to django
internals. Someone should check that I understand the usage of
empty_strings_allowed properly. It seems that perhaps EmailField should
have empty_strings_allowed set to False since empty strings don't
validate.

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

Django

unread,
Jul 6, 2015, 8:07:24 AM7/6/15
to django-...@googlegroups.com
#25065: Should EmailField empty_strings_allowed be False
-------------------------------------+-------------------------------------
Reporter: CrazyCasta | Owner: nobody
Type: Uncategorized | Status: closed
Component: Database layer | Version: 1.8
(models, ORM) |
Severity: Normal | Resolution: invalid
Keywords: | Triage Stage:
| Unreviewed
Has patch: 0 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0

Easy pickings: 0 | UI/UX: 0
-------------------------------------+-------------------------------------
Changes (by timgraham):

* status: new => closed
* needs_better_patch: => 0
* resolution: => invalid
* needs_tests: => 0
* needs_docs: => 0


Comment:

`empty_strings_allowed` controls whether empty values may be stored as an
empty string or if they must be stored as null. In the case of
`EmailField`, empty strings are fine. See also the second paragraph in the
[https://docs.djangoproject.com/en/stable/ref/models/fields/#null
Field.null] docs.

--
Ticket URL: <https://code.djangoproject.com/ticket/25065#comment:1>

Reply all
Reply to author
Forward
0 new messages