https://bugzilla.wikimedia.org/show_bug.cgi?id=55249
--- Comment #1 from Kunal Mehta (Legoktm) legoktm.wikipedia@gmail.com --- Can you reproduce the problem?
If so, please change output(u"%s" % e) to output(u"%r"% e) and add a comment with the output you get. Additionally, please tell us what code page you are using (run 'chcp' in a dos box) and the language of your windows version.
Thanks.