#18119: add DomainNameValidator to validate Internet Domain Names
------------------------------+------------------------------------
     Reporter:  michele       |                    Owner:  nobody
         Type:  New feature   |                   Status:  new
    Component:  Core (Other)  |                  Version:  1.4
     Severity:  Normal        |               Resolution:
     Keywords:  validators    |             Triage Stage:  Accepted
    Has patch:  1             |      Needs documentation:  1
  Needs tests:  1             |  Patch needs improvement:  1
Easy pickings:  0             |                    UI/UX:  0
------------------------------+------------------------------------
Changes (by claudep):

 * needs_docs:   => 1
 * needs_better_patch:   => 1
 * needs_tests:   => 1
 * stage:  Unreviewed => Accepted


Comment:

 I think it is a good idea to centralize domain name validation. I detected
 at least three points where we could use this validator
 (django/core/mail/message.py, django/core/validators.py (URLValidator),
 django/utils/html.py).

 For DRY reasons, the domain regex part should be shared with URLValidator.
 In `__init__`, just use {{{self.accept_idna = kwargs.pop('accept_idna',
 True)}}}

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

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/django-updates?hl=en.

Reply via email to