[Zope] locale: unknown locale: de_DE@euro

Florian Konnertz florian.konnertz@web.de
Sun, 16 Feb 2003 11:00:35 +0100


Hi!

Florian Konnertz wrote:
> Hello,
> 
> I encountered a locale issue while installing ZWiki-0.15 on my box here 
> in germany (Zope-2.6.1, Python-2.1.3)
...

>   File /usr/local/lib/python2.1/locale.py, line 339, in getdefaultlocale
>   File /usr/local/lib/python2.1/locale.py, line 272, in _parse_localename
> ValueError: unknown locale: de_DE@euro
> 
> 
> This is the opportunity for me to learn the localization stuff... :-)
...

Ok, i fixed this by adding

     # Next three lines patched by ../FloK, see
     # http://openspirit.homelinux.net/noowiki/python/Locale
     if '@' in fullname:
         # '@' is sometimes used as encoding delimiter.
         fullname = fullname.replace('@', '.')

to normalize() in locale.py

See this thread: 
http://groups.google.de/groups?hl=en&lr=&ie=UTF-8&threadm=HJvD8.13869%2448.1363768%40zwoll1.home.nl&rnum=1&prev=/groups%3Fq%3Dlocale%2B%2540euro%2Bgroup:comp.lang.python.*%26hl%3Den%26lr%3D%26ie%3DUTF-8%26selm%3DHJvD8.13869%252448.1363768%2540zwoll1.home.nl%26rnum%3D1


Zope starts without errors now.

Best regards,
Florian





-- 
Florian Konnertz   ---   http://www.florian-konnertz.de	
http://openspirit.homelinux.net/noowiki/FrontPage
Improved ZWiki about all topics, especially consciousness research
and wisdom traditions