ValueError too many values to unpack

Raised by:

django/core/mail/message.py (line 105)

Traceback (most recent call last):
  File "python2.7/site-packages/django/core/handlers/base.py", line 111, in get_response
    response = wrapped_callback(request, *callback_args, **callback_kwargs)
  File "python2.7/site-packages/django/views/generic/base.py", line 69, in view
    return self.dispatch(request, *args, **kwargs)
  File "python2.7/site-packages/braces/views/_access.py", line 64, in dispatch
    request, *args, **kwargs)
  File "python2.7/site-packages/django/views/generic/base.py", line 87, in dispatch
    return handler(request, *args, **kwargs)
  File "python2.7/site-packages/django/views/generic/edit.py", line 207, in post
    return super(BaseCreateView, self).post(request, *args, **kwargs)
  File "python2.7/site-packages/django/views/generic/edit.py", line 173, in post
    return self.form_valid(form)
  File "private.py", line 1, in private_function
    private_function()
  File "python2.7/site-packages/django/db/models/base.py", line 589, in save
    force_update=force_update, update_fields=update_fields)
  File "python2.7/site-packages/django/db/models/base.py", line 626, in save_base
    update_fields=update_fields, raw=raw, using=using)
  File "python2.7/site-packages/django/dispatch/dispatcher.py", line 198, in send
    response = receiver(signal=self, sender=sender, **named)
  File "private.py", line 1, in private_function
    private_function()
  File "private.py", line 1, in private_function
    private_function()
  File "private.py", line 1, in private_function
    private_function()
  File "python2.7/site-packages/templated_email/__init__.py", line 74, in send_templated_mail
    headers=headers, **kwargs)
  File "python2.7/site-packages/templated_email/backends/vanilla_django.py", line 184, in send
    e.send(fail_silently)
  File "python2.7/site-packages/django/core/mail/message.py", line 286, in send
    return self.get_connection(fail_silently).send_messages([self])
  File "python2.7/site-packages/django/core/mail/backends/smtp.py", line 99, in send_messages
    sent = self._send(message)
  File "python2.7/site-packages/django/core/mail/backends/smtp.py", line 112, in _send
    for addr in email_message.recipients()]
  File "python2.7/site-packages/django/core/mail/message.py", line 105, in sanitize_address
    nm, addr = addr
ValueError: too many values to unpack

How to reproduce

from django.core.mail import EmailMessage

e = EmailMessage(
    subject='test',
    body='test',
    from_email='from@example.org',
    to=[['test1@example.org', 'test2@example.org', 'test3@example.org']],
)
e.send()

How to fix

to parameter of EmailMessage (or send_mail) should not be a list of lists, but only a list. Change to to a list.