1π
β
The trick is that Django is expecting a tuple of tuples in ADMINS, but you have actually only given a single tuple: the outer parentheses are effectively ignored, because in Python it is not the parens that define a tuple, but the comma.
The code in the mail_admins function tries to extract the emails from the setting by doing [a[1] for a in settings.ADMINS]
, so in your case it will take the second letter of the name and the second letter of the email address β presumably those both happen to be βmβ.
Do this instead:
ADMINS = (('{name}', '{email@mycompany.com}'),)
Note the extra comma before the final close paren.
π€Daniel Roseman
Source:stackexchange.com