#12005 closed (invalid)
django.forms.fields.email_re doesn't handle single-letter subdomains
Reported by: | Gumnos | Owned by: | Daniel Gonzalez Gasull |
---|---|---|---|
Component: | Forms | Version: | dev |
Severity: | Keywords: | email_re subdomain speed single letter | |
Cc: | Jason Yosinski | Triage Stage: | Accepted |
Has patch: | yes | Needs documentation: | no |
Needs tests: | no | Patch needs improvement: | no |
Easy pickings: | no | UI/UX: | no |
Description
When domain-validating logic was moved from validators to forms.fields.email_re single-letter sub-domains are no longer caught. There were also some speed issues when processing longer email addresses that were resolved in 1.1.1 and 1.0.4 that this patch should also address in a similar manner. There may be a similar issue with forms.fields.url_re but I didn't get a chance to hack that too.
Attachments (2)
Change History (9)
comment:1 by , 15 years ago
comment:2 by , 15 years ago
comment:3 by , 15 years ago
milestone: | → 1.2 |
---|---|
Triage Stage: | Unreviewed → Accepted |
comment:4 by , 15 years ago
Owner: | changed from | to
---|
by , 15 years ago
Attachment: | EmailField_single_letter_domains.diff added |
---|
comment:5 by , 15 years ago
Resolution: | → invalid |
---|---|
Status: | new → closed |
It isn't clear if this ticket refers to 2nd level or 3rd level domains. Also, it isn't clear if with "caught" it means single-letter subdomains should be valid or rejected. In any case:
Single-letter 2nd level domains are valid:
http://en.wikipedia.org/wiki/Single-letter_second-level_domain#Active_single-letter_domains
Single-letter 3rd level domains are valid too: #1275
In both cases, Django forms is working as expected. Please see attached diff for tests.
comment:6 by , 15 years ago
Cc: | added |
---|
This may conflict with r11603 but should resolve the same email_re issue there.