nodemailer / smtp-server

Create custom SMTP servers on the fly
Other
846 stars 145 forks source link

Receive duplicate emails from outlook.com #160

Closed ducdev closed 3 years ago

ducdev commented 3 years ago

Hi,

I sent emails from my personal email address ***@live.com to an email address running with smtp-server. I realized that I received duplicated emails, more than twice for each copy. I think that the sender didn't know that the emails were arrived, there should be a way to let them know about delivery status.

Hope to hear back from you. Thanks for making this great package.

jvlobo commented 3 years ago

I'm also seeing this behaviour on my server. I keep receiving the same email over and over. Is there a way to stop this? Maybe, as @ducdev said, the server needs to respond that the email arrived successfully? Thanks!

ducdev commented 3 years ago

I'm also seeing this behaviour on my server. I keep receiving the same email over and over. Is there a way to stop this? Maybe, as @ducdev said, the server needs to respond that the email arrived successfully? Thanks!

Bro, I'm happy with https://www.npmjs.com/package/node-mailin after all.

jvlobo commented 3 years ago

Thanks mate, will take a look :)

andris9 commented 3 years ago

You get multiple emails if you do not properly acknowledge the message so that the sender would get a proper 250 success response. If there's a 4xx or 5xx response or timeout then the sender tries again several times.

jvlobo commented 3 years ago

Thanks @andris9 How can we properly acknowledge the message so that the sender gets a proper 250 success response?

andris9 commented 3 years ago

You have to always run the callback like shown here. This triggers the 250 response. If the callback is not called or is called with an error then the message is most probably retried

jvlobo commented 3 years ago

Thank you @andris9 👍🏽

andrealeo83 commented 3 years ago

thanks @andris9