WMFLabs Email delivery problems (SPF records?)

Hi everybody,

I found that emails sent from projects hosted on WMFLabs are using various ways to get their emails delivered - which results in an extremely inconsistent delivery rate. Besides the mx-out01.wmflabs.org and mx-out02.wmflabs.org servers, it seems like tools on the WMFLabs don’t have a unified approach to solve the problem of delivering emails.

It seems like the Wikimedia Space used a trick to let Gmail do all the deliveries (or maybe not, I’m really not an expert on emails), so the recipient’s mailing system will check gmail.com's SPF record instead of discuss-space.wmflabs.org. But if it is not this case, discuss-space.wmflabs.org has no SPF records at all, which will make all emails deemed as spam automatically.

While some other WMFLabs-hosted sites, such as UTRS, the ticketing system for unblock requests on English Wikipedia, will mask sender (bounce address?) as wmflabs.org without subdomains, thus avoiding the problem that all subdomains of wmflabs.org have no SPF records. However, I do hear people complaining to me that because their emails from the UTRS system ended up in spam, they missed crucial questions from enwiki admins regarding their requests, thus forgot this matter and have to waste extra time to redo the whole process.

But either way, it seems to me that emails from WMFLabs do seem to have a delivery issue, or at least, not as good as those MediaWiki notification emails from wikimedia.org. For things like UTRS, email delivery is crucial.

I do hope there could be better ways to improve the system. Not everyone’s using Gmail; there are plenty people using their local service, those provided by their ISP, or regional internet companies like Yandex for Russia, Naver for South Korea, Netease and Tencent for China, etc. I have personally spoken to staff working in Tencent a few years ago to get them to whitelist Wikimedia domains - Tencent’s email takes up probably half of all email usage in China. I don’t think it is difficult to use third-party services like Mailgun for things like the Wikimedia Space, but if that’s not a choice, it will definitely be better to improve the Labs’ email services.

1 Like

On November I received here private message from system about problems with sending e-mails to me. I’ve never received any e-mail from Wikimedia Space (should I?). Maybe this is releated with above issue.

1 Like

well… it went into spam again

And I guess my whitelisting won’t work because so far putting discuss-space.wmflabs.org into whitelist does nothing, and obviously I can’t whitelist everything from gmail.com. It seems to be impossible to even try to whitelist emails from the Wikimedia Space - at least on the email service I’m using.

1 Like

Hi @Techyan, thank you for looking into this. Space’s email setup is more than provisional, and slightly complicated.

System emails are sent through Discourse using Wikimedia Cloud’s SMTP, and we also use a GMail account for enabling email replies (and not a @wikimedia.org account because we haven’t been able to make it work so far in this prototype setup).

The result is that, yes, some email providers are filtering our notifications because SPF check failures. Discourse keeps a record of email bounces and most emails seem to arrive to most users, but as you point out this is because the big email providers seem to be distributing our emails anyway.

I don’t know how we can fix this problem in our current circumstances. I have searched a bit, and found https://meta.discourse.org/t/setting-up-email-how-to-create-a-valid-spf-record/129690 but I am not sure it provides any solution for us.