Skip to content

Commit 6c8e0dc

Browse files
committed
Fix i18n support for help and log.warning in image
Change-Id: I6e2764aaf4b8c0efa78872646a7b3482ba044dc8
1 parent 7956561 commit 6c8e0dc

3 files changed

Lines changed: 145 additions & 141 deletions

File tree

openstackclient/image/client.py

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@
1616
import logging
1717

1818
from openstackclient.common import utils
19+
from openstackclient.i18n import _
1920

2021

2122
LOG = logging.getLogger(__name__)
@@ -82,7 +83,7 @@ def build_option_parser(parser):
8283
'--os-image-api-version',
8384
metavar='<image-api-version>',
8485
default=utils.env('OS_IMAGE_API_VERSION'),
85-
help='Image API version, default=' +
86-
DEFAULT_API_VERSION +
87-
' (Env: OS_IMAGE_API_VERSION)')
86+
help=_('Image API version, default=%s (Env: OS_IMAGE_API_VERSION)') %
87+
DEFAULT_API_VERSION,
88+
)
8889
return parser

0 commit comments

Comments
 (0)