[openstack-dev] [Heat] lazy translation is breaking Heat
Jay S Bryant
jsbryant at us.ibm.com
Tue Feb 18 17:14:28 UTC 2014
All,
Myself and Jim Carey have been working on getting the right solution for
making lazy_translation work through Nova and Cinder.
The patch should have also had changes to remove the use of str() in any
LOG or exception messages as well as the removal of any places where
strings were being '+' ed together. In the case of Cinder we are doing it
as two separate patches that are dependent. I am surprised that this
change got past Jenkins. In the case of Cinder and Nova unit test caught
a number of problems.
We will make sure to work with Liang Chen to avoid this happening again.
Jay S. Bryant
IBM Cinder Subject Matter Expert & Cinder Core Member
Department 7YLA, Building 015-2, Office E125, Rochester, MN
Telephone: (507) 253-4270, FAX (507) 253-6410
TIE Line: 553-4270
E-Mail: jsbryant at us.ibm.com
--------------------------------------------------------------------
All the world's a stage and most of us are desperately unrehearsed.
-- Sean O'Casey
--------------------------------------------------------------------
From: Ben Nemec <openstack at nemebean.com>
To: openstack-dev at lists.openstack.org,
Date: 02/18/2014 10:37 AM
Subject: Re: [openstack-dev] [Heat] lazy translation is breaking
Heat
On 2014-02-18 09:15, Christopher Armstrong wrote:
This change was recently merged:
https://review.openstack.org/#/c/69133/
Unfortunately it didn't enable lazy translations for the unit tests, so it
didn't catch the many places in Heat that won't work when lazy
translations are enabled. Notably there are a lot of cases where the code
adds the result of a call to _() with another string, and Message objects
(which are returned from _ when lazy translations are enabled) can't be
added, resulting in an exception being raised.
I think the best course of action would be to revert this change, and then
reintroduce it along with patches to fix all the problems, while enabling
it for the unit tests so bugs won't be reintroduced in the future.
Agreed. That behavior was intentional because we shouldn't be adding
translated strings that way, but obviously it needs to be fixed before
lazy translation is enabled. :-)
Interestingly it also didn't fail any of the tempest tests, I'm not sure
why.
That is kind of concerning. I see that the error does show up in the logs
a couple of times though:
http://logs.openstack.org/33/69133/5/gate/gate-tempest-dsvm-full/d6aa1bd/logs/screen-h-api.txt.gz#_2014-02-17_17_38_25_521
Maybe this is something that would need the new error message test enabled
to be caught?
--
IRC: radix
Christopher Armstrong
_______________________________________________
OpenStack-dev mailing list
OpenStack-dev at lists.openstack.org
http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev
_______________________________________________
OpenStack-dev mailing list
OpenStack-dev at lists.openstack.org
http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstack.org/pipermail/openstack-dev/attachments/20140218/41e00572/attachment.html>
More information about the OpenStack-dev
mailing list