2009-01-02 13:40:03 |
Lorenzo Sfarra |
description |
Forwarding a message causes a TypeError in the email.attach (or email.attach_file) call (provided by django itself[1]).
Traceback:
Environment:
Request Method: POST
Request URL: http://localhost:8000/sendmail/
Django Version: 1.1 pre-alpha SVN-9692
Python Version: 2.5.2
Installed Applications:
['django.contrib.auth',
'django.contrib.contenttypes',
'django.contrib.sessions',
'django.contrib.sites',
'enchanted.webmail']
Installed Middleware:
('django.middleware.common.CommonMiddleware',
'django.contrib.sessions.middleware.SessionMiddleware',
'django.contrib.auth.middleware.AuthenticationMiddleware',
'django.middleware.doc.XViewMiddleware')
Traceback:
File "/var/lib/python-support/python2.5/django/core/handlers/base.py" in get_response
86. response = callback(request, *callback_args, **callback_kwargs)
File "/var/lib/python-support/python2.5/django/contrib/auth/decorators.py" in __call__
67. return self.view_func(request, *args, **kwargs)
File "/home/lorenzo/projects/enchanted/../enchanted/webmail/sendviews.py" in sendmail
211. return _sendmail(request, fwd_message)
File "/home/lorenzo/projects/enchanted/../enchanted/webmail/sendviews.py" in _sendmail
296. email.send()
File "/var/lib/python-support/python2.5/django/core/mail.py" in send
275. return self.get_connection(fail_silently).send_messages([self])
File "/var/lib/python-support/python2.5/django/core/mail.py" in send_messages
172. sent = self._send(message)
File "/var/lib/python-support/python2.5/django/core/mail.py" in _send
186. email_message.message().as_string())
File "/usr/lib/python2.5/email/message.py" in as_string
131. g.flatten(self, unixfrom=unixfrom)
File "/usr/lib/python2.5/email/generator.py" in flatten
84. self._write(msg)
File "/usr/lib/python2.5/email/generator.py" in _write
109. self._dispatch(msg)
File "/usr/lib/python2.5/email/generator.py" in _dispatch
135. meth(msg)
File "/usr/lib/python2.5/email/generator.py" in _handle_multipart
201. g.flatten(part, unixfrom=False)
File "/usr/lib/python2.5/email/generator.py" in flatten
84. self._write(msg)
File "/usr/lib/python2.5/email/generator.py" in _write
109. self._dispatch(msg)
File "/usr/lib/python2.5/email/generator.py" in _dispatch
135. meth(msg)
File "/usr/lib/python2.5/email/generator.py" in _handle_message
266. g.flatten(msg.get_payload(0), unixfrom=False)
File "/usr/lib/python2.5/email/message.py" in get_payload
185. raise TypeError('Expected list, got %s' % type(self._payload))
Exception Type: TypeError at /sendmail/
Exception Value: Expected list, got <type 'str'> |
Forwarding a message causes a TypeError in the email.attach (or email.attach_file) call (provided by django itself[1]).
[1] http://docs.djangoproject.com/en/dev/topics/email/
Traceback:
Environment:
Request Method: POST
Request URL: http://localhost:8000/sendmail/
Django Version: 1.1 pre-alpha SVN-9692
Python Version: 2.5.2
Installed Applications:
['django.contrib.auth',
'django.contrib.contenttypes',
'django.contrib.sessions',
'django.contrib.sites',
'enchanted.webmail']
Installed Middleware:
('django.middleware.common.CommonMiddleware',
'django.contrib.sessions.middleware.SessionMiddleware',
'django.contrib.auth.middleware.AuthenticationMiddleware',
'django.middleware.doc.XViewMiddleware')
Traceback:
File "/var/lib/python-support/python2.5/django/core/handlers/base.py" in get_response
86. response = callback(request, *callback_args, **callback_kwargs)
File "/var/lib/python-support/python2.5/django/contrib/auth/decorators.py" in __call__
67. return self.view_func(request, *args, **kwargs)
File "/home/lorenzo/projects/enchanted/../enchanted/webmail/sendviews.py" in sendmail
211. return _sendmail(request, fwd_message)
File "/home/lorenzo/projects/enchanted/../enchanted/webmail/sendviews.py" in _sendmail
296. email.send()
File "/var/lib/python-support/python2.5/django/core/mail.py" in send
275. return self.get_connection(fail_silently).send_messages([self])
File "/var/lib/python-support/python2.5/django/core/mail.py" in send_messages
172. sent = self._send(message)
File "/var/lib/python-support/python2.5/django/core/mail.py" in _send
186. email_message.message().as_string())
File "/usr/lib/python2.5/email/message.py" in as_string
131. g.flatten(self, unixfrom=unixfrom)
File "/usr/lib/python2.5/email/generator.py" in flatten
84. self._write(msg)
File "/usr/lib/python2.5/email/generator.py" in _write
109. self._dispatch(msg)
File "/usr/lib/python2.5/email/generator.py" in _dispatch
135. meth(msg)
File "/usr/lib/python2.5/email/generator.py" in _handle_multipart
201. g.flatten(part, unixfrom=False)
File "/usr/lib/python2.5/email/generator.py" in flatten
84. self._write(msg)
File "/usr/lib/python2.5/email/generator.py" in _write
109. self._dispatch(msg)
File "/usr/lib/python2.5/email/generator.py" in _dispatch
135. meth(msg)
File "/usr/lib/python2.5/email/generator.py" in _handle_message
266. g.flatten(msg.get_payload(0), unixfrom=False)
File "/usr/lib/python2.5/email/message.py" in get_payload
185. raise TypeError('Expected list, got %s' % type(self._payload))
Exception Type: TypeError at /sendmail/
Exception Value: Expected list, got <type 'str'> |
|