yahoo-eng-team team mailing list archive
-
yahoo-eng-team team
-
Mailing list archive
-
Message #18456
[Bug 1351478] [NEW] cleanup translation in a file - replacing with underscore
Public bug reported:
As suggested by:
https://review.openstack.org/#/c/107755/1/horizon/templatetags/sizeformat.py
This file
https://github.com/openstack/horizon/blob/master/horizon/templatetags/sizeformat.py
should cleanup some of the translation stuff.
from django.utils import translation
...
return translation.ungettext_lazy("%(size)d Byte",
"%(size)d Bytes", 0) % {'size': 0}
should be replaced with:
from django.utils.translation import ugettext_lazy as _
...
return _("%(size)d Byte", "%(size)d Bytes", 0) % {'size': 0}
replace instances with _.
** Affects: horizon
Importance: Undecided
Status: New
** Tags: low-hanging-fruit
** Tags added: low-hanging-fruit
--
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to OpenStack Dashboard (Horizon).
https://bugs.launchpad.net/bugs/1351478
Title:
cleanup translation in a file - replacing with underscore
Status in OpenStack Dashboard (Horizon):
New
Bug description:
As suggested by:
https://review.openstack.org/#/c/107755/1/horizon/templatetags/sizeformat.py
This file
https://github.com/openstack/horizon/blob/master/horizon/templatetags/sizeformat.py
should cleanup some of the translation stuff.
from django.utils import translation
...
return translation.ungettext_lazy("%(size)d Byte",
"%(size)d Bytes", 0) % {'size': 0}
should be replaced with:
from django.utils.translation import ugettext_lazy as _
...
return _("%(size)d Byte", "%(size)d Bytes", 0) % {'size': 0}
replace instances with _.
To manage notifications about this bug go to:
https://bugs.launchpad.net/horizon/+bug/1351478/+subscriptions
Follow ups
References