Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #60966 > unrolled thread

Python 2.7.5: Strange and differing behavior depending on sys.setdefaultencoding being set

Started byHans-Peter Jansen <hpj@urpla.net>
First post2013-12-03 23:32 +0100
Last post2013-12-03 23:32 +0100
Articles 1 — 1 participant

Back to article view | Back to comp.lang.python


Contents

  Python 2.7.5: Strange and differing behavior depending on sys.setdefaultencoding being set Hans-Peter Jansen <hpj@urpla.net> - 2013-12-03 23:32 +0100

#60966 — Python 2.7.5: Strange and differing behavior depending on sys.setdefaultencoding being set

FromHans-Peter Jansen <hpj@urpla.net>
Date2013-12-03 23:32 +0100
SubjectPython 2.7.5: Strange and differing behavior depending on sys.setdefaultencoding being set
Message-ID<mailman.3533.1386109953.18130.python-list@python.org>

[Multipart message — attachments visible in raw view] — view raw

Hi,

I'm experiencing strange behavior with attached code, that differs depending 
on sys.setdefaultencoding being set or not. If it is set, the code works as 
expected, if not - what should be the usual case - the code fails with some 
non-sensible traceback.

I tried to boil it down to a comprehensible state, but some LOC are still 
involved. I use similar code to represent database records, where the repr's 
appear in user visible logs for example.

It is greatly appreciated, if some kind soul could shed some light on this 
ungrateful behavior.

Thanks in advance,
Pete

[toc] | [standalone]


Back to top | Article view | comp.lang.python


csiph-web