URL and email fields need to allow custom validators
|Reported by:||Jacob||Owned by:||floguy|
|Cc:||joel@…, listuser@…||Triage Stage:||Accepted|
|Has patch:||yes||Needs documentation:||no|
|Needs tests:||no||Patch needs improvement:||yes|
See #3989 and #6019 -- in both cases, people want to define "email" or "URL" a bit differently than Django does by default. In both cases, changing the default isn't the answer since that'll just make new people unhappy with the new defaults.
So, I should be able to do something like this:
rfc2822pattern = re.compile(...) # ... email = models.EmailField(pattern=rfc2822pattern)
That's just a strawman proposal, of course -- I'm not sure I like that syntax.
Change History (14)
comment:2 Changed 9 years ago by
|Owner:||changed from nobody to floguy|
|Status:||new → assigned|
comment:5 Changed 9 years ago by
|Patch needs improvement:||set|
|Triage Stage:||Ready for checkin → Accepted|