On 27 Nov 2007, at 17:14 , Nathan Yergler wrote:
On 11/27/07, Philipp von Weitershausen <[EMAIL PROTECTED]>
Nathan Yergler wrote:
I've run into a problem this morning with i18n in Zope3, and I'm not
exactly sure what the appropriate approach is. We have a set of
African translations, paticularly Zulu (zu) and Sotho (st) that are
getting picked up correctly. Upon some inspection it appears that
i18n negotiator is skipping over them, with an exception such as:
The desired locale is not available.
Upon inspection I can confirm that the locales which are not working
are those without .xml files in the data directory. So a few
* Is there an external source for those .xml files, or do we create
The XML files are from the ICU repository
(http://www.unicode.org/cldr/). AFAIK we're using quite an old
of the files. The problem is we can't simply upgrade to the newest
release because the XML DTD changed and the code in zope.i18n.locales
isn't very robust regarding DTD changes (which is quite hard
don't think anybody would object if the files and the code were
Where "wink" is defined as "so why don't you go ahead and do it", I
* Translation seems to work OK (in the case of Zulu, not Sotho) from
ZPT, but not from Python; does this sound sane, or perhaps I'm
How are you translating from Python?
Ah; I wasn't passing in the context. Thanks.
Right. zope.i18n.translate() needs a context that it can adapt to
IUserPreferredLanguages so that it can deduct the target language (it
can't guess it from thin air). This context is the request (sic!).
Zope-Dev maillist - Zope-Dev@zope.org
** No cross posts or HTML encoding! **
(Related lists -