Issue 12 in pycopia: Can't use ezmail with non-ascii payload.

3 views
Skip to first unread message

pyc...@googlecode.com

unread,
Apr 4, 2014, 8:57:57 PM4/4/14
to pyc...@googlegroups.com
Status: Accepted
Owner: keith.d...@gmail.com
Labels: Type-Defect Priority-Medium

New issue 12 by keith.d...@gmail.com: Can't use ezmail with non-ascii
payload.
http://code.google.com/p/pycopia/issues/detail?id=12

Traceback (most recent call last):
File "/usr/local/bin/runtest", line 33, in <module>
sys.exit(runtest(sys.argv))
File "/usr/local/bin/runtest", line 21, in runtest
return tri(argv)

File "/usr/lib64/python2.7/site-packages/pycopia_QA-1.0.dev-py2.7.egg/pycopia/QA/shellinterface.py",
line 218, in __call__
self.runner.finalize()

File "/usr/lib64/python2.7/site-packages/pycopia_QA-1.0.dev-py2.7.egg/pycopia/QA/testrunner.py",
line 375, in finalize
rpt.finalize()

File "/usr/lib64/python2.7/site-packages/pycopia_QA-1.0.dev-py2.7.egg/pycopia/reports/Email.py",
line 84, in finalize
ezmail.mail(self._message)

File "/usr/lib64/python2.7/site-packages/pycopia_core-1.0.dev-py2.7.egg/pycopia/ezmail.py",
line 292, in mail
return ezmail(obj, To, From, subject, cc, bcc, extra_headers)

File "/usr/lib64/python2.7/site-packages/pycopia_core-1.0.dev-py2.7.egg/pycopia/ezmail.py",
line 281, in ezmail
errs = outer.send(smtp)

File "/usr/lib64/python2.7/site-packages/pycopia_core-1.0.dev-py2.7.egg/pycopia/ezmail.py",
line 106, in send
return smtp.sendmail(self.mail_from, self.rcpt_to, self.as_string(0),
mopts, rcptopts)

File "/usr/lib64/python2.7/site-packages/pycopia_core-1.0.dev-py2.7.egg/pycopia/inet/SMTP.py",
line 694, in sendmail
msg = msg.encode("ascii")
UnicodeEncodeError: 'ascii' codec can't encode character u'\u2018' in
position 29988: ordinal not in range(128)


--
You received this message because this project is configured to send all
issue notifications to this address.
You may adjust your notification preferences at:
https://code.google.com/hosting/settings

pyc...@googlecode.com

unread,
Apr 25, 2014, 6:03:53 PM4/25/14
to pyc...@googlegroups.com
Updates:
Status: Fixed

Comment #1 on issue 12 by keith.d...@gmail.com: Can't use ezmail with
non-ascii payload.
http://code.google.com/p/pycopia/issues/detail?id=12

Made changes to allow non-ascii attachments. Tested with UTF-8 attachment
payload.
Reply all
Reply to author
Forward
0 new messages