c2c-oerpscenario team mailing list archive
-
c2c-oerpscenario team
-
Mailing list archive
-
Message #17664
Re: [Bug 724057] Re: translation needs context but it doesn't always exist
A Dissabte, 26 de febrer de 2011 20:51:42, xrg va escriure:
> So, why don't we simply fix the 1% remaining where context is not passed
> right? For the second one, 'en_US' does not mean "no translation". On the
> contrary, it still tries to locate en_US strings. We'd better not break
> the framework (there is some reason gettext bails out when no language is
> in context, we have designed it to be so).
Because workflow is still not ready to pass context. I provided a patch for v5
and was not accepted because it would break API.
It was not integrated into v6 either.
--
Albert Cervera i Areny
http://www.NaN-tic.com
OpenERP Partners
Tel: +34 93 553 18 03
skype: nan-oficina
http://twitter.com/albertnan
http://www.nan-tic.com/blog
--
You received this bug notification because you are a member of C2C
OERPScenario, which is subscribed to the OpenERP Project Group.
https://bugs.launchpad.net/bugs/724057
Title:
translation needs context but it doesn't always exist
Status in OpenERP Server:
Confirmed
Bug description:
OpenERP v6:
class GettextAlias in tools/translate.py requires a valid context
available where _() was called. In some cases the context variable
does not exsits or is not properly initialized. The attached patch
provides a workarround by searching current user's language in order
to find to which language it should translate.
The patch is based on a Jay Vora patch provided in a v5 bug report:
https://bugs.launchpad.net/openobject-addons/+bug/432504
References