请问地址在哪里(我想问一下地址在哪里)
650
2022-05-29
Python: email-validator验证Email地址
文档:
PyPI: https://pypi.org/project/email-validator/
Github: https://github.com/JoshData/python-email-validator
安装
pip install email-validator
1
代码实例
from email_validator import validate_email, EmailNotValidError email = "my+address@mydomain.tld" try: # Validate. valid = validate_email(email) # Update with the normalized form. email = valid.email except EmailNotValidError as e: # email is not valid, exception message is human-readable print(str(e))
1
2
3
4
5
6
7
8
9
10
11
12
13
14
Python
版权声明:本文内容由网络用户投稿,版权归原作者所有,本站不拥有其著作权,亦不承担相应法律责任。如果您发现本站中有涉嫌抄袭或描述失实的内容,请联系我们jiasou666@gmail.com 处理,核实后本网站将在24小时内删除侵权内容。