From 2f00fcda77af8b87d009cd92facd6a5a6ea4acd8 Mon Sep 17 00:00:00 2001 From: TerryHowe Date: Wed, 4 Nov 2015 11:20:43 -0700 Subject: [PATCH] Allow int version numbers in the clouds.yaml OSC blows up if you try to use for example identity_api_version: 2 in the clouds.yaml. It will only work with a string '2'. This fixes that. Change-Id: I785d37a288126a1582464e907c7f9c9947bac27c --- openstackclient/shell.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/openstackclient/shell.py b/openstackclient/shell.py index 72521cb275..5b4939a217 100644 --- a/openstackclient/shell.py +++ b/openstackclient/shell.py @@ -280,7 +280,7 @@ class OpenStackShell(app.App): for mod in clientmanager.PLUGIN_MODULES: default_version = getattr(mod, 'DEFAULT_API_VERSION', None) option = mod.API_VERSION_OPTION.replace('os_', '') - version_opt = self.cloud.config.get(option, default_version) + version_opt = str(self.cloud.config.get(option, default_version)) if version_opt: api = mod.API_NAME self.api_version[api] = version_opt