Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

validate_address can't handle display name #175

Open
ChrisCPO opened this issue Nov 15, 2017 · 1 comment
Open

validate_address can't handle display name #175

ChrisCPO opened this issue Nov 15, 2017 · 1 comment

Comments

@ChrisCPO
Copy link

This looks like a possible bug; address.validate_address returns none when passed a email string with a display name. Yet parse can handle it.

>>> text = 'Fooman <[email protected]>'
>>> address.validate_address(text)
>>> None
>>> address.validate_address('[email protected]')
>>> fooman@bar.com
>>> address.parse('Fooman <[email protected]>')
>>>Fooman <fooman@bar.com>
@horkhe
Copy link
Member

horkhe commented Nov 16, 2017

I was not the one who originally wrote this, but the docstring states that the method takes addr_spec which i suppose means just email address, no display name. I personally see no problem in making it work on addresses that include display name. So I am tagging that as enhancement. But it is so minor, that I doubt it will ever be implemented unless you wanna venture a PR :)

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

No branches or pull requests

2 participants