smtplib.send_message

"Stephen J. Turnbull" <[email protected]> Mon, 20 Jun 2011 02:37:10 +0900
Newsgroups gmane.comp.python.mime.devel
Message-ID <[email protected]>
R. David Murray writes:

 > So, opinions:  should I implement the heuristics, or should I refuse
 > to guess and bail if from_addr and/or to_addrs is None and there are
 > any Resent headers in the message?  (Third alternative: continue to
 > auto-detect it if there is only one set, as the current patch
 > does.)

The heuristics should be implemented as a separate function or method,
and a way to specify the function to call.  My taste would be to
default the control variable/attribute to None, but if the use case
you're thinking about is sufficiently common or you want backward
compatibility, you could default it to your heuristics.