From 5fa3dd50d7b9a02811b1ff5c48ce8f4a406202c4 Mon Sep 17 00:00:00 2001 From: "Jay S. Bryant" Date: Fri, 20 Feb 2015 15:21:55 -0600 Subject: [PATCH] Namespace updates for _i18n and imageutils & fileutils The _i18n and imageutils modules only have changes to move oslo.utils to the oslo_utils namespace and oslo.i18n to oslo_i18n. So, I have lumped these two small changes into this one patch. Current HEAD in OSLO: --------------------- commit e589dde0721a0a67e4030813e582afec6e70d042 Date: Wed Feb 18 03:08:12 2015 +0000 Merge "Have a little fun with release notes" Changes merged with this patch: --------------------- _i18n.py 0cc741a9 - switch to oslo_i18n imageutils.py ac17de97 - Use oslo_utils instead of deprecated oslo.utils fileutils.py ac17de97 - Use oslo_utils instead of deprecated oslo.utils Change-Id: I749dd8869bbc07d980300e0acbf3903ff7b297cd --- cinder/openstack/common/_i18n.py | 6 +++--- cinder/openstack/common/fileutils.py | 2 +- cinder/openstack/common/imageutils.py | 2 +- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/cinder/openstack/common/_i18n.py b/cinder/openstack/common/_i18n.py index 20f9b3ce8..46eb21446 100644 --- a/cinder/openstack/common/_i18n.py +++ b/cinder/openstack/common/_i18n.py @@ -17,14 +17,14 @@ See http://docs.openstack.org/developer/oslo.i18n/usage.html """ try: - import oslo.i18n + import oslo_i18n # NOTE(dhellmann): This reference to o-s-l-o will be replaced by the # application name when this module is synced into the separate # repository. It is OK to have more than one translation function # using the same domain, since there will still only be one message # catalog. - _translators = oslo.i18n.TranslatorFactory(domain='cinder') + _translators = oslo_i18n.TranslatorFactory(domain='cinder') # The primary translation function using the well-known name "_" _ = _translators.primary @@ -40,6 +40,6 @@ try: _LC = _translators.log_critical except ImportError: # NOTE(dims): Support for cases where a project wants to use - # code from cinder-incubator, but is not ready to be internationalized + # code from oslo-incubator, but is not ready to be internationalized # (like tempest) _ = _LI = _LW = _LE = _LC = lambda x: x diff --git a/cinder/openstack/common/fileutils.py b/cinder/openstack/common/fileutils.py index 6cacf22b2..9097c35d4 100644 --- a/cinder/openstack/common/fileutils.py +++ b/cinder/openstack/common/fileutils.py @@ -20,7 +20,7 @@ import os import stat import tempfile -from oslo.utils import excutils +from oslo_utils import excutils LOG = logging.getLogger(__name__) diff --git a/cinder/openstack/common/imageutils.py b/cinder/openstack/common/imageutils.py index bdb8263d0..9a85e8512 100644 --- a/cinder/openstack/common/imageutils.py +++ b/cinder/openstack/common/imageutils.py @@ -21,7 +21,7 @@ Helper methods to deal with images. import re -from oslo.utils import strutils +from oslo_utils import strutils from cinder.openstack.common._i18n import _ -- 2.45.2