Using oslo_* instead of oslo.*
Changes: * using oslo_config instead of oslo.config * using oslo_concurrency instead of oslo.concurrency * using oslo_db instead of oslo.db * using oslo_i18n instead of oslo.i18n * using oslo_messaging instead of oslo.messaging * using oslo_middleware instead of oslo.middleware * using oslo_serialization instead of oslo.serialization * using oslo_utils instead of oslo.utils Change-Id: Ib0f18603ca5b0885256a39a96a3620d05260a272 Closes-bug: #1414587
This commit is contained in:
parent
623ec0f185
commit
fd4e08d07f
@ -16,10 +16,10 @@
|
|||||||
# It's based on oslo.i18n usage in OpenStack Keystone project and
|
# It's based on oslo.i18n usage in OpenStack Keystone project and
|
||||||
# recommendations from http://docs.openstack.org/developer/oslo.i18n/usage.html
|
# recommendations from http://docs.openstack.org/developer/oslo.i18n/usage.html
|
||||||
|
|
||||||
from oslo import i18n
|
import oslo_i18n
|
||||||
|
|
||||||
|
|
||||||
_translators = i18n.TranslatorFactory(domain='sahara')
|
_translators = oslo_i18n.TranslatorFactory(domain='sahara')
|
||||||
|
|
||||||
# The primary translation function using the well-known name "_"
|
# The primary translation function using the well-known name "_"
|
||||||
_ = _translators.primary
|
_ = _translators.primary
|
||||||
|
@ -12,7 +12,7 @@
|
|||||||
# License for the specific language governing permissions and limitations
|
# License for the specific language governing permissions and limitations
|
||||||
# under the License.
|
# under the License.
|
||||||
|
|
||||||
from oslo.config import cfg
|
from oslo_config import cfg
|
||||||
from oslo_log import log as logging
|
from oslo_log import log as logging
|
||||||
|
|
||||||
from sahara import exceptions as ex
|
from sahara import exceptions as ex
|
||||||
|
@ -13,9 +13,9 @@
|
|||||||
# See the License for the specific language governing permissions and
|
# See the License for the specific language governing permissions and
|
||||||
# limitations under the License.
|
# limitations under the License.
|
||||||
|
|
||||||
from oslo import i18n
|
import oslo_i18n
|
||||||
|
|
||||||
# NOTE(slukjanov): i18n.enable_lazy() must be called before
|
# NOTE(slukjanov): i18n.enable_lazy() must be called before
|
||||||
# sahara.utils.i18n._() is called to ensure it has the desired
|
# sahara.utils.i18n._() is called to ensure it has the desired
|
||||||
# lazy lookup behavior.
|
# lazy lookup behavior.
|
||||||
i18n.enable_lazy()
|
oslo_i18n.enable_lazy()
|
||||||
|
Loading…
Reference in New Issue
Block a user