Code

Opened 3 years ago

Closed 3 years ago

Last modified 3 years ago

#15022 closed (duplicate)

contrib.auth.User email field length is insufficient for Facebook proxy email addresses

Reported by: alun@… Owned by: nobody
Component: contrib.auth Version: 1.2
Severity: Keywords: email
Cc: Triage Stage: Unreviewed
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: UI/UX:

Description

As of Django 1.2, the max length of the email field on the User model is 75 characters. This is not sufficient to accomodate the random anonymized proxy email addresses generated by Facebook, which are usually well over 75 characters long: e.g. "apps+71659511993.252800001.671353761e563e7852e650c93c3b821c@…".

This poses a problem for integrating with 3rd-party authentication systems; as do other User charfield limits like those on the username, first_name and last_name fields (which are each limited to 30 characters.) In the case of Django's builtin models, whose schemas are awkward to override, I can't see any advantage in being parsimonious with charfield sizes.

Attachments (0)

Change History (2)

comment:1 Changed 3 years ago by russellm

  • Needs documentation unset
  • Needs tests unset
  • Patch needs improvement unset
  • Resolution set to duplicate
  • Status changed from new to closed

Duplicate of #12900, #11579, #11365, and many others.

The advantage is backwards compatibility. Every single Django site in existence that uses contrib.auth has a synchronized database with an email field of length 75 characters. Yes, this length is too short for some uses. But we don't currently have a way to ship migrations and ensure that they are applied.

The likely fix for this is #3011 -- making the user module user-definable. It isn't as simple as "just increase the max_length".

comment:2 Changed 3 years ago by anonymous

Whoops, sorry for the spam - looks like I did the world's least diligent search for preexisting tickets.

Add Comment

Modify Ticket

Change Properties
<Author field>
Action
as closed
as The resolution will be set. Next status will be 'closed'
The resolution will be deleted. Next status will be 'new'
Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.