Mike Dewhirst
unread,Nov 24, 2014, 6:14:55 PM11/24/14Sign in to reply to author
Sign in to forward
You do not have permission to delete messages in this group
Sign in to report message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to django...@googlegroups.com
Somehow recently the character causing the logging problem is one of
many which are working well in the browser. They are unicode subscripted
numbers for example, \u2083 is subscripted "3".
But in logging under Python 3.4 it causes
--- Logging error ---
Traceback (most recent call last):
File "C:\Python34\Lib\logging\__init__.py", line 980, in emit
stream.write(msg)
File "C:\Users\mike\env\xxdx3\lib\encodings\cp1252.py", line 19, in
encode
return codecs.charmap_encode(input,self.errors,encoding_table)[0]
UnicodeEncodeError: 'charmap' codec can't encode characters in position
287-288: character maps to <undefined>
<stack trace omitted>
I assume this is because I'm running the Django dev server on Windows 8.1
I have reviewed the Python logging docs and seen no reference to code
pages or even unicode.
There is no logging error when switching to Python 2.7
Is there anything I can do to rein this in?
Thanks
Mike