-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1
On 23.06.2012 00:03, Merlijn van Deen wrote:
My guess: you are running a German Windows version, which will give you a German error message, with non-ASCII characters, when the
I would *NEVER EVER* use windows...(!) ;)))
connection fails. This error message is encoded in the latin-1 ('western european') encoding, and decoding it as plain ascii fails. Feel free to substitute German for French, Spanish or any other language that might have non-ascii error messages.
Regarding the language you might be right, using 'locale' gives me some non-standard locale. So how to get the english (decodable as ascii) original/default message? If I would know the error raised, I could check the error message for problematic chars and try to avoid this...
We should probably decode it using the current console encoding, but it's not really clear to me what the pitfalls would be.
Would a 'locale.setlocale(locale.LC_ALL, 'en_US')' in front of the problematic output help at all?
Thank for your answer! Greetings DrTrigon