"=?ISO-8859-1?Q?Trond_Endrest=F8l?=" <trond.endres...@ximalas.info>:
> Marko Rauhamaa <ma...@pacujo.net> writes: >> $ python3 >> >>> locale.setlocale(locale.LC_TIME, ('fi_FI', 'UTF-8')) >> >>> time.strftime("%a, %d %b %Y %H:%M:%S %z (%Z)") >> 'ti, 03 tammi\xa0 2012 14:51:57 +0200 (EET)' > > It may be OS-specific. You're right. It's a generic linux problem (in the coreutils rpm of Fedora). An analogous C program demonstrates the same issue. > Your sample code runs fine on FreeBSD/i386 > trond@enterprise:~>python3.2 > >>> locale.setlocale(locale.LC_TIME, ('fi_FI', 'UTF-8')) > >>> time.strftime("%a, %d %b %Y %H:%M:%S %z (%Z)") > 'Ti, 03 Tam 2012 15:03:15 +0100 (CET)' Well, "Ti" and "Tam" probably shouldn't be capitalized... Marko -- http://mail.python.org/mailman/listinfo/python-list