Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.python > #18965
| Date | 2012-01-14 08:25 +0000 |
|---|---|
| From | Chris Withers <chris@simplistix.co.uk> |
| Subject | Re: SMTPHandler and Unicode |
| References | <6cc17e2c-6560-4bc2-968f-1d23f288dc7c@b35g2000yqi.googlegroups.com> <mailman.256.1278328627.1673.python-list@python.org> <02f2f8f9-e563-4677-97e2-74e91c623853@c10g2000yqi.googlegroups.com> <4F109153.3040409@simplistix.co.uk> |
| Newsgroups | comp.lang.python |
| Message-ID | <mailman.4740.1326529526.27778.python-list@python.org> (permalink) |
On 13/01/2012 20:17, Chris Withers wrote:
>> Your package has the same unicode problem :
>> import logging,logging.handlers
>> from mailinglogger.MailingLogger import MailingLogger
>> mailingLogger = MailingLogger(mailhost=('smtp.example.com',
>> 25),fromaddr='toto@example.com',toaddrs=('toto@example.com',))
>> LOG = logging.getLogger()
>> LOG.addHandler(mailingLogger)
>> LOG.error(u"sans accent")
>> LOG.error(u"accentu\u00E9")
>>
>> --> UnicodeEncodeError: 'ascii' codec can't encode character u'\xe9'
>> in position 7: ordinal not in range(128)
>
> It's taken a ridiculously long amount of time (sadly due to no-one else
> complaining) but this is now fixed in the source control for
> mailinglogger, and will be in the next release:
>
> https://github.com/Simplistix/testfixtures
Sorry, I meant this:
https://github.com/Simplistix/mailinglogger/commit/1c95f532c65ab18e1dd8513e1aa1ae328a19d249
cheers,
Chris
--
Simplistix - Content Management, Batch Processing & Python Consulting
- http://www.simplistix.co.uk
Back to comp.lang.python | Previous | Next | Find similar | Unroll thread
Re: SMTPHandler and Unicode Chris Withers <chris@simplistix.co.uk> - 2012-01-14 08:25 +0000
csiph-web