On 21/03/2012, at 2:00 AM, Tom Evans wrote: > On Tue, Mar 20, 2012 at 5:41 PM, Donald Stufft <donald.stu...@gmail.com> > wrote: >> What Alex said. If it was _just_ the username then you'd have a good >> argument for >> a setting like that. However there's username, email, some people want to >> add >> fields, some want to get rid of, or combine fields. Ideally any change would >> work >> for as many of those use cases without turning into a giant set of boolean >> flags >> that drastically alter the DB schema. >> > > No-one is talking about a 'giant set of boolean flags', or drastically > altering the DB schema. > > The email field needs to accept email addresses of up to 254 octets. > The username field should be able to hold common fields used as a > username, eg emails, and hence needs to be longer. > > That is one boolean flag. No more. If you want more flexibility on the > model, you would use the proposed pluggable auth models.
Ok - I see two separate problems here. Problem 1 -- the default value for max_length on EmailField. This isn't an auth.User issue -- it's a problem wherever an email address is specified. This is a bug. Problem 2 -- that you can't fit an email address into User.username. This is a feature request. Fixing *these* problems is orthogonal. I'm not wild about the idea of introducing a setting that will immediately be deprecated, but I'm not sure I see an alternative, either; so I can get behind introducing a ALLOW_RFC5321_EMAIL_ADDRESSES setting whose sole purpose is to increase the max_length on Email to 254, phased in with the usual 2-version deprecation plan, with all the warnings and so on. However, any fix for problem 2 that only addresses the length of username would only be a piecemeal workaround, introducing a setting to allow for 1 specific use case (email as username) while ignoring all the other complaints and requests that people have had for auth.User -- as well as inconveniencing those that *want* a 30 character username limit. I'd much rather spend the time actually fixing auth.User than just paper over one specific problem. Yours, Russ Magee %-) -- You received this message because you are subscribed to the Google Groups "Django developers" group. To post to this group, send email to django-developers@googlegroups.com. To unsubscribe from this group, send email to django-developers+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/django-developers?hl=en.