bpo-31507 Add docstring to parseaddr function in email.utils.parseadd… · python/cpython@93c0885 (original) (raw)

Skip to content

Provide feedback

Saved searches

Use saved searches to filter your results more quickly

Sign up

Appearance settings

Commit 93c0885

AstroCat84Mariatta

authored and

committed

(cherry picked from commit 9e7b9b2)

File tree

1 file changed

lines changed

1 file changed

lines changed

Original file line number Diff line number Diff line change
@@ -215,6 +215,12 @@ def parsedate_to_datetime(data):
215 215
216 216
217 217 def parseaddr(addr):
218 +"""
219 + Parse addr into its constituent realname and email address parts.
220 +
221 + Return a tuple of realname and email address, unless the parse fails, in
222 + which case return a 2-tuple of ('', '').
223 + """
218 224 addrs = _AddressList(addr).addresslist
219 225 if not addrs:
220 226 return '', ''