The max length of the email is 254 #1291

Closed
wants to merge 1 commit into
from

Conversation

Projects
None yet
2 participants
@goinnn
Contributor

goinnn commented Jun 20, 2013

How you can see in the next link the max length of an email is 254 chars. Now we have only 75 chars...

http://stackoverflow.com/questions/386294/what-is-the-maximum-length-of-a-valid-email-address

Related commit:

bfcda77

@mjtamlyn

This comment has been minimized.

Show comment Hide comment
@mjtamlyn

mjtamlyn Jun 20, 2013

Member

At present we do not have the ability to make schema changes in core and so we cannot change the underlying database field of any given model field. Similarly, the form field should take its size from the relevant model field. These things can be overridden in your application. It's a known problem with Django, but this solution is too simple.

Thanks for your concern.

Member

mjtamlyn commented Jun 20, 2013

At present we do not have the ability to make schema changes in core and so we cannot change the underlying database field of any given model field. Similarly, the form field should take its size from the relevant model field. These things can be overridden in your application. It's a known problem with Django, but this solution is too simple.

Thanks for your concern.

@mjtamlyn mjtamlyn closed this Jun 20, 2013

@mjtamlyn

This comment has been minimized.

Show comment Hide comment
@mjtamlyn

mjtamlyn Jun 20, 2013

Member

Actually, reading your commit more closely, the change to the password reset form is probably reasonable for the same reasons as in the commit you gave. In any case this would need a ticket on trac and test cases.

Member

mjtamlyn commented Jun 20, 2013

Actually, reading your commit more closely, the change to the password reset form is probably reasonable for the same reasons as in the commit you gave. In any case this would need a ticket on trac and test cases.

@goinnn

This comment has been minimized.

Show comment Hide comment
@goinnn

goinnn Jun 20, 2013

Contributor

@mjtamlyn Ok I understand the database problem, I didn't think about this...

But although I override in my application there is a problem with the validator (EmailValidator), because always the validator says that a long email is invalid.

I think that this is a great bug. In a lot of projects I have to patch django for this...

Contributor

goinnn commented Jun 20, 2013

@mjtamlyn Ok I understand the database problem, I didn't think about this...

But although I override in my application there is a problem with the validator (EmailValidator), because always the validator says that a long email is invalid.

I think that this is a great bug. In a lot of projects I have to patch django for this...

@mjtamlyn

This comment has been minimized.

Show comment Hide comment
@mjtamlyn

mjtamlyn Jun 20, 2013

Member

Agreed, the email validator should be updated. If you open a ticket (or have a search for an existing one) then we can move forwards with this. It is possible you're not the first person to have reported this, I'm not sure what decisions might have been made before.

Member

mjtamlyn commented Jun 20, 2013

Agreed, the email validator should be updated. If you open a ticket (or have a search for an existing one) then we can move forwards with this. It is possible you're not the first person to have reported this, I'm not sure what decisions might have been made before.

@goinnn

This comment has been minimized.

Show comment Hide comment
@goinnn

goinnn Jun 20, 2013

Contributor

@mjtamlyn Ok I will it.

The changes of the django/forms/fields.py and django/db/models/fields/init.py modifing 254 for 75 I think that these are a good changes... even I think that 75 could be a settings variable, EMAIL_MAX_LENGTH

Contributor

goinnn commented Jun 20, 2013

@mjtamlyn Ok I will it.

The changes of the django/forms/fields.py and django/db/models/fields/init.py modifing 254 for 75 I think that these are a good changes... even I think that 75 could be a settings variable, EMAIL_MAX_LENGTH

@mjtamlyn

This comment has been minimized.

Show comment Hide comment
@mjtamlyn

mjtamlyn Jun 20, 2013

Member

Introducing a new setting is highly unlikely to be accepted - we have too many as it is and global state smells.

Member

mjtamlyn commented Jun 20, 2013

Introducing a new setting is highly unlikely to be accepted - we have too many as it is and global state smells.

@goinnn

This comment has been minimized.

Show comment Hide comment
@goinnn

goinnn Jun 20, 2013

Contributor

This would be only to can change this in our project settings easier. The another way you have to change it in every model... and also we would have the literal 254 in some places

Contributor

goinnn commented Jun 20, 2013

This would be only to can change this in our project settings easier. The another way you have to change it in every model... and also we would have the literal 254 in some places

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment