You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
What steps will reproduce the problem?
1.
import i18n
# add multiple domain catalogs for gettext
i18n.default_config['domains'] = ['messages1', 'messages2']
What is the expected output? What do you see instead?
It only loads messages from the last domain in the 'domains' list instead of
merging them.
What version of the product are you using? On what operating system?
Webapp2 2.5.2 on Google App Engine
Please provide any additional information below.
In the 'I18nStore.load_translations' method there is an if _trans is an
instance of NullTranslations, but python gettext documentation
(http://docs.python.org/2/library/gettext.html#the-nulltranslations-class)
states that all translations objects inherit from NullTranslations, so this
always returns True and sets 'trans_null' instead of merging all provided
domains translations into 'trans'.
A possible fix is to replace:
if isinstance(_trans, NullTranslations):
with this:
if isinstance(_trans, i18n.NullTranslations) and \
not isinstance(_trans, babel.support.Translations):
Original issue reported on code.google.com by [email protected] on 3 Oct 2013 at 4:53
The text was updated successfully, but these errors were encountered:
Original issue reported on code.google.com by
[email protected]
on 3 Oct 2013 at 4:53The text was updated successfully, but these errors were encountered: