Looking at /var/log/phd/daemons.log I found out the following:
```
[01-Apr-2015 17:30:55 UTC] [2015-04-01 17:30:55] EXCEPTION: (PhutilProxyException) Error while executing task ID 11483554 from queue. {>} (phpmailerException) SMTP Error: The following recipients failed: #REMOVED# at [<phabricator>/externals/phpmailer/class.phpmailer.php:738]
[01-Apr-2015 17:30:55 UTC] #0 PHPMailer::SmtpSend(string, string) called at [<phabricator>/externals/phpmailer/class.phpmailer.php:576]
[01-Apr-2015 17:30:55 UTC] #1 PHPMailer::Send() called at [<phabricator>/src/applications/metamta/adapter/PhabricatorMailImplementationPHPMailerAdapter.php:118]
[01-Apr-2015 17:30:55 UTC] #2 PhabricatorMailImplementationPHPMailerAdapter::send() called at [<phabricator>/src/applications/metamta/storage/PhabricatorMetaMTAMail.php:676]
[01-Apr-2015 17:30:55 UTC] #3 PhabricatorMetaMTAMail::sendNow() called at [<phabricator>/src/applications/metamta/PhabricatorMetaMTAWorker.php:26]
[01-Apr-2015 17:30:55 UTC] #4 PhabricatorMetaMTAWorker::doWork() called at [<phabricator>/src/infrastructure/daemon/workers/PhabricatorWorker.php:91]
[01-Apr-2015 17:30:55 UTC] #5 PhabricatorWorker::executeTask() called at [<phabricator>/src/infrastructure/daemon/workers/storage/PhabricatorWorkerActiveTask.php:158]
[01-Apr-2015 17:30:55 UTC] #6 PhabricatorWorkerActiveTask::executeTask() called at [<phabricator>/src/infrastructure/daemon/workers/PhabricatorTaskmasterDaemon.php:19]
[01-Apr-2015 17:30:55 UTC] #7 PhabricatorTaskmasterDaemon::run() called at [<phutil>/src/daemon/PhutilDaemon.php:91]
```
The #REMOVED# part is right now 4 distinct address but I think they are more (reasoning below). It should be easy to find out with the following command:
```
grep recipients /var/log/phd/daemons.log | egrep -o '[[:alnum:]]+@[[:alnum:]]+\.[[:alnum:]]+' | sort | uniq -c |sort -rn
```
I see a couple of issues:
* How do we handle non existent email addresses in phabricator? phab is trying to send emails to those addresses and is failing.
These addresses are all @wikimedia.org or @mediawiki.org which are WMF owned domains and the relay MTA is authoritative for them so it is directly answering to phabricator with a 550 refusing to accept the message. For the rest, the MTA will accept the message from phabricator and then be refused itself by the corresponding MTA generating a DSN, which probably gets lost. So we probably got more than the 4 reported by the command above.
* Phab is not handling very nicely the failure. To my phab unfamiliar eye, it seems like the Taskmaster is spewing out a stacktrace (a well formulated one btw) and then dying when email sending fails. I am thinking it should handle such an occasion more gracefully. Logging it and then terminating normally.