Ticket #5056 enhancement closed duplicate

Opened 3 years ago

Last modified 3 years ago

twistd - specify log encoding

Reported by: berwin22 Owned by:
Priority: normal Milestone:
Component: core Keywords: codec log encoding ordinal
Cc: Branch:
Author: Launchpad Bug:

Description

I would say that this issue can be marked as fixed once the user can specify the log format encoding (utf-8, ansii, etc) when invoking twistd.

Personally, I'd like to see unicode support. Currently, the default encoding is ansii, even if the terminal supports utf-8, and when you try to print a unicode charactor: <unicode instance at 0x9108a10 with str error:

Traceback (most recent call last):

File "/usr/lib/python2.6/dist-packages/twisted/python/reflect.py", line 546, in _safeFormat

return formatter(o)

UnicodeEncodeError: 'ascii' codec can't encode character u'\u0411' in position 0: ordinal not in range(128)

I should point out the two similar issues:  http://twistedmatrix.com/trac/ticket/3368  http://twistedmatrix.com/trac/ticket/1990 The fix for 1990 will still be an ansii encoded file, with unicode escape sequences. The fix has also not been included in the core repository.

Change History

1

Changed 3 years ago by exarkun

  • status changed from new to closed
  • resolution set to duplicate

There's also #989, which I think encompasses all of the same stuff as this ticket describes.

Note: See TracTickets for help on using tickets.