[Patches] [ python-Patches-1158909 ] patch for bug 1158490 (locale breakage)

SourceForge.net noreply at sourceforge.net
Wed Mar 9 20:59:36 CET 2005


Patches item #1158909, was opened at 2005-03-08 10:40
Message generated for change (Comment added) made by calvin
You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=305470&aid=1158909&group_id=5470

Category: Library (Lib)
Group: None
Status: Open
Resolution: None
Priority: 5
Submitted By: Wummel (calvin)
Assigned to: Nobody/Anonymous (nobody)
Summary: patch for bug 1158490 (locale breakage)

Initial Comment:
Patch fixes the locale breakage mentioned in the bug by
using the normalized locale var. Patch is against
current CVS.

----------------------------------------------------------------------

>Comment By: Wummel (calvin)
Date: 2005-03-09 20:59

Message:
Logged In: YES 
user_id=9205

I forgot an example. this fails for me on current CVS:
$ env LANG=de_DE at euro python2.5 -c "import locale; print
locale.getdefaultlocale()"
Traceback (most recent call last):
  File "<string>", line 1, in ?
  File "/usr/local/lib/python2.5/locale.py", line 357, in
getdefaultlocale
    return _parse_localename(localename)
  File "/usr/local/lib/python2.5/locale.py", line 280, in
_parse_localename
    code, modifier = code.split('@')
ValueError: need more than 1 value to unpack

The error is that the @ char is searched in the original
locale, but the split is done on the normalized locale.
Hence the unpack error.

----------------------------------------------------------------------

Comment By: Serge Orlov (sorlov)
Date: 2005-03-09 20:26

Message:
Logged In: YES 
user_id=1235914

I don't get what this patch fixes. It actually changes
handling of locales with @ sign, but there is no mentioning
of that in bug 1158490. What do I miss?

----------------------------------------------------------------------

You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=305470&aid=1158909&group_id=5470


More information about the Patches mailing list