Kaydet (Commit) 7d97c574 authored tarafından Tim Graham's avatar Tim Graham

Refs #23763 -- Fixed SMTPServer Python 3.5 deprecation warning in mail test.

üst f5da4380
......@@ -868,6 +868,9 @@ class FakeSMTPServer(smtpd.SMTPServer, threading.Thread):
def __init__(self, *args, **kwargs):
threading.Thread.__init__(self)
# New kwarg added in Python 3.5; default switching to False in 3.6.
if sys.version_info >= (3, 5):
kwargs['decode_data'] = True
smtpd.SMTPServer.__init__(self, *args, **kwargs)
self._sink = []
self.active = False
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment