Marko Rauhamaa <ma...@pacujo.net>:

> "=?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.

Actually, it's working as designed, no bug at all.

It turns out the "garbage" character is the nonbreaking space:

    >>> print(time.strftime("%a, %d %b %Y %H:%M:%S %z (%Z)"))
    ke, 04 tammi  2012 15:03:21 +0200 (EET)

The apparent intent is to make all month abbreviations equally long (six
characters).


Marko
-- 
http://mail.python.org/mailman/listinfo/python-list

Reply via email to