From: Mitsuhiro Tanino Date: Tue, 24 Jun 2014 23:40:36 +0000 (-0400) Subject: Misuse of i18n log translation to output error message X-Git-Url: https://review.fuel-infra.org/gitweb?a=commitdiff_plain;h=663eadfb2b7facbae7ba2cf6fe579355e1cc5e02;p=openstack-build%2Fcinder-build.git Misuse of i18n log translation to output error message I found a misuse of i18n log translation for error message in "cinder/volume/drivers/lvm.py'. The "%s' can not be translated. In this case, the "message' must be i18ning and then the "message" should be output using LOG.error(). Change-Id: I4495522d337764dc28186225f4594a227ac3e555 Signed-off-by: Mitsuhiro Tanino Closes-Bug: 1334334 --- diff --git a/cinder/volume/drivers/lvm.py b/cinder/volume/drivers/lvm.py index e3f539c10..dc98a7870 100644 --- a/cinder/volume/drivers/lvm.py +++ b/cinder/volume/drivers/lvm.py @@ -573,9 +573,9 @@ class LVMISCSIDriver(LVMVolumeDriver, driver.ISCSIDriver): try: (vg for vg in vg_list if vg['name'] == dest_vg).next() except StopIteration: - message = ("Destination Volume Group %s does not exist" % + message = (_("Destination Volume Group %s does not exist") % dest_vg) - LOG.error(_('%s'), message) + LOG.error(message) return false_ret helper = utils.get_root_helper()