Page MenuHomePhabricator

Update the "SES" and "sendmail" mailers for the new API; remove "encoding"
ClosedPublic

Authored by epriestley on Jan 14 2019, 5:02 PM.
Tags
None
Referenced Files
Unknown Object (File)
Sat, Oct 1, 5:51 AM
Unknown Object (File)
Fri, Sep 30, 11:35 PM
Unknown Object (File)
Wed, Sep 21, 4:12 AM
Unknown Object (File)
Sat, Sep 17, 9:28 PM
Unknown Object (File)
Sat, Sep 17, 2:07 AM
Unknown Object (File)
Thu, Sep 15, 11:29 AM
Unknown Object (File)
Thu, Sep 15, 11:12 AM
Unknown Object (File)
Mon, Sep 12, 6:20 PM
Subscribers
None

Details

Summary

Ref T13222. Ref T920. This is the last of the upstream adapter updates.

Test Plan
  • Sent mail with SES.
  • Sent mail with "sendmail". I don't have sendmail actually configured to an upstream MTA so I'm not 100% sure this worked, but the sendmail binary didn't complain and almost all of the code is shared with SES, so I'm reasonably confident this actually works.

Diff Detail

Repository
rP Phabricator
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

I definitely reviewed almost this exact same code, but I have completely lost it in the stack of email-related changes recently. If I recall, I complained about the unused variable, checking for truthiness instead of using strlen for all the fields that PHPMailer wants, and the base64 attachment encoding thing. The truthiness checks make sense now that all those properties are objects instead of bare strings.

externals/phpmailer/class.phpmailer-lite.php
98

Still an unused variable.

src/applications/metamta/adapter/PhabricatorMailSendmailAdapter.php
3

Hooray!

This revision is now accepted and ready to land.Jan 16 2019, 6:59 PM

Aha, this is what triggered my deja vu: D19959.

Don't tell anyone, but I copy/pasted all of these.

bwahaha

This revision was automatically updated to reflect the committed changes.
src/applications/metamta/adapter/PhabricatorMailSendmailAdapter.php
101–105

Oh, and I believe this ("..does NOT support..") wasn't right, the way to do it is just a little tricky (->AltBody).

Or maybe this was true when written, then we updated PHPMailerLite, then it became untrue?

In either case, we build HTML + Text mail now.