[issue32727] smtplib's SMTP.send_message behaves differently with from_addr and to_addrs

2018-01-31 Thread Ned Deily
Ned Deily added the comment: New changeset 209108bd6997258948d13f48f2b5a2f1220c1a35 by Ned Deily (Stéphane Wirtel) in branch '3.7': bpo-32727: smtplib's SMTP.send_message behaves differently with from_addr and to_addrs (#5451)

[issue32727] smtplib's SMTP.send_message behaves differently with from_addr and to_addrs

2018-01-31 Thread R. David Murray
R. David Murray added the comment: Thanks, Stéphane. -- resolution: -> fixed stage: patch review -> resolved status: open -> closed versions: -Python 3.4, Python 3.5 ___ Python tracker

[issue32727] smtplib's SMTP.send_message behaves differently with from_addr and to_addrs

2018-01-31 Thread R. David Murray
R. David Murray added the comment: New changeset 85a92d00bd278022cc00fda6b124c06f614c5ebb by R. David Murray (Miss Islington (bot)) in branch '3.6': bpo-32727: smtplib's SMTP.send_message behaves differently with from_addr and to_addrs (GH-5451) (#5455)

[issue32727] smtplib's SMTP.send_message behaves differently with from_addr and to_addrs

2018-01-30 Thread miss-islington
Change by miss-islington : -- pull_requests: +5283 ___ Python tracker ___

[issue32727] smtplib's SMTP.send_message behaves differently with from_addr and to_addrs

2018-01-30 Thread R. David Murray
R. David Murray added the comment: New changeset 8d83e4ba7823827bcbc119db887004d5c3a63dc6 by R. David Murray (Stéphane Wirtel) in branch 'master': bpo-32727: smtplib's SMTP.send_message behaves differently with from_addr and to_addrs (#5451)

[issue32727] smtplib's SMTP.send_message behaves differently with from_addr and to_addrs

2018-01-30 Thread Stéphane Wirtel
Stéphane Wirtel added the comment: The new test crashes without my fix but once we use the fix, all the tests pass. I have modified the SimSMTPServer.process_manage method -- ___ Python tracker

[issue32727] smtplib's SMTP.send_message behaves differently with from_addr and to_addrs

2018-01-30 Thread R. David Murray
R. David Murray added the comment: We need a test that will fail without your fix. -- ___ Python tracker ___

[issue32727] smtplib's SMTP.send_message behaves differently with from_addr and to_addrs

2018-01-30 Thread Stéphane Wirtel
Stéphane Wirtel added the comment: yep, you can take a look but all the tests are green on Travis, maybe you will understand why I don't see the interest of my new test. you are the master for the email part ;-) -- ___ Python

[issue32727] smtplib's SMTP.send_message behaves differently with from_addr and to_addrs

2018-01-30 Thread R. David Murray
R. David Murray added the comment: The current test suite had better work fine without your new test, otherwise your fix broke something :) I will take a look. -- ___ Python tracker

[issue32727] smtplib's SMTP.send_message behaves differently with from_addr and to_addrs

2018-01-30 Thread Stéphane Wirtel
Stéphane Wirtel added the comment: @r.david.murray I just updated the PR with a test, but I am not sure about it, could you give me your opinion because the current test suite works fine without my new test. -- ___ Python

[issue32727] smtplib's SMTP.send_message behaves differently with from_addr and to_addrs

2018-01-30 Thread R. David Murray
R. David Murray added the comment: Yes, you'll have to write a test. Add a test after test_send_unicode_without_SMTPUTF8, but put the unicode in the name field of the 'from' address and test that it is accepted. You should be able to figure out how to check for

[issue32727] smtplib's SMTP.send_message behaves differently with from_addr and to_addrs

2018-01-30 Thread Stéphane Wirtel
Change by Stéphane Wirtel : -- keywords: +patch pull_requests: +5282 stage: -> patch review ___ Python tracker ___

[issue32727] smtplib's SMTP.send_message behaves differently with from_addr and to_addrs

2018-01-30 Thread Stéphane Wirtel
Stéphane Wirtel added the comment: @r.david.murray I am interested with your opinion about a test for this PR, if you have an idea, because all the tests pass on my laptop -- ___ Python tracker

[issue32727] smtplib's SMTP.send_message behaves differently with from_addr and to_addrs

2018-01-30 Thread Stéphane Wirtel
Stéphane Wirtel added the comment: @r.david.murray I started to work on a fix. -- ___ Python tracker ___

[issue32727] smtplib's SMTP.send_message behaves differently with from_addr and to_addrs

2018-01-30 Thread Michaël Lemaire
Michaël Lemaire added the comment: Oups @r.david.murray, just saw I posted over your message, and removed you from the nozy list, sorry. -- nosy: +r.david.murray ___ Python tracker

[issue32727] smtplib's SMTP.send_message behaves differently with from_addr and to_addrs

2018-01-30 Thread Michaël Lemaire
Michaël Lemaire added the comment: Sure : #coding: utf-8 import email.utils from email.message import EmailMessage from smtplib import SMTP m = EmailMessage() m['From'] = email.utils.formataddr(("Michaël", "mich...@example.com")) m['To'] = email.utils.formataddr(("René",

[issue32727] smtplib's SMTP.send_message behaves differently with from_addr and to_addrs

2018-01-30 Thread R. David Murray
R. David Murray added the comment: Yes, that looks like a bug. Should be a one line bug fix, plus tests and news item if someone wants to make a PR... -- nosy: +r.david.murray ___ Python tracker

[issue32727] smtplib's SMTP.send_message behaves differently with from_addr and to_addrs

2018-01-30 Thread Stéphane Wirtel
Stéphane Wirtel added the comment: Do you have an example with a test? Thank you -- nosy: +matrixise ___ Python tracker ___

[issue32727] smtplib's SMTP.send_message behaves differently with from_addr and to_addrs

2018-01-30 Thread Michaël Lemaire
New submission from Michaël Lemaire : Hi, I noticed that SMTP.send_message, when getting the sender and recipients from the Message object, strips the name from recipients (to keep only the address), but not from the sender. if from_addr is None: #