proposal: net/mail: special error for empty group address #28638
Labels
FrozenDueToAge
Proposal
WaitingForInfo
Issue is not actionable because of missing required information, which needs to be provided.
Milestone
Empty group address is often used to hide email recipients, for example,
(http://www.postfix.org/postconf.5.html#undisclosed_recipients_header)
The mail.ParseAddress() function returns nil and error on such inputs now, and this error ("mail: empty group") is not exported. Hence it is difficult to parse a wide range of emails.
I suggest to declare an exported error variable that could be used to detect the case. It will not change behavior of any existing Go program, but it will significantly help for email parsing.
The text was updated successfully, but these errors were encountered: