On Fri, Sep 03, 2004 at 01:26:38PM +0200, Marcin Wojdyr wrote: > If there are non-ascii chars in PTL it doesn't work: [...] > File "/usr/lib/python2.3/site-packages/quixote/http_response.py", line > 210, in set_body self.body = unicode(body).encode(self.charset) > UnicodeDecodeError: 'ascii' codec can't decode byte 0xc5 in position 954: > ordinal not in range(128) You need to use unicode strings if you want to use non-ascii characters. > I changed > self.body = unicode(body).encode(self.charset) > to: > self.body = str(body).decode("UTF-8").encode(self.charset) > and it works as expected. > I have self.charset=="ISO-8859-2". That is almost certainly not what you want. Neil