Opened 14 years ago

Closed 14 years ago

Last modified 13 years ago

#12900 closed Uncategorized (duplicate)

EmailField max_length of 75 characters should be 256 acccording to RFC 5321

Reported by: artem.skvira@… Owned by: nobody
Component: Database layer (models, ORM) Version: 1.1
Severity: Normal Keywords:
Cc: tomasz.zielinski@… Triage Stage: Unreviewed
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no

Description

As per http://tools.ietf.org/html/rfc5321#section-4.5.3 email addresses can take up to 256 characters, which is not the case with current declaration of EmailField.

Can that be fixed since currenty one has to use external to auth.User profile model to allow for longer emails.

Thanks

Change History (2)

comment:1 by Russell Keith-Magee, 14 years ago

Resolution: duplicate
Status: newclosed

Duplicate of #11579, #11365, and others.

comment:2 by Tomasz Zieliński, 13 years ago

Cc: tomasz.zielinski@… added
Easy pickings: unset
Severity: Normal
Type: Uncategorized

JFYI I was successfull with monkey-patching of auth.User model with:

User._meta.get_field_by_name('email')[0].max_length = 256

There was "only" one problem with this - when I put it into models.py which also contained my custom UserProfile model, then depending on the position (in source file) of the monkey patch line relative to UserProfile model, the backreference from UserProfile to User was - or was not created. Other than that, everything has so far worked like a charm, including South migrations.

Note: See TracTickets for help on using tickets.
Back to Top