summaryrefslogtreecommitdiff
path: root/openstackclient/shell.py
diff options
context:
space:
mode:
authorTerryHowe <terrylhowe@gmail.com>2015-08-10 12:45:35 -0600
committerTerry Howe <terrylhowe@gmail.com>2015-10-30 11:16:36 +0900
commitbfebac82825a7242ad4e2923e3b71d38b391f08e (patch)
tree83a8621dfdaf7fea87966c97cdd300d9dc54bce6 /openstackclient/shell.py
parent85a03945f0b5da0ec5778a929e08a641f427513a (diff)
downloadpython-openstackclient-bfebac82825a7242ad4e2923e3b71d38b391f08e.tar.gz
Allow debug to be set in configuration file
The current default value for debug in cliff is False. Cloud config assumes that it was set that way on the command line and does not overlay it with the value from the configuration file. Cliff bug: https://bugs.launchpad.net/python-cliff/+bug/1483378 Change-Id: I66d82b489b2241dbcd1e1350e94259a54ce09de7
Diffstat (limited to 'openstackclient/shell.py')
-rw-r--r--openstackclient/shell.py6
1 files changed, 6 insertions, 0 deletions
diff --git a/openstackclient/shell.py b/openstackclient/shell.py
index 72f663a0..f7704efc 100644
--- a/openstackclient/shell.py
+++ b/openstackclient/shell.py
@@ -232,10 +232,16 @@ class OpenStackShell(app.App):
},
)
+ # TODO(thowe): Change cliff so the default value for debug
+ # can be set to None.
+ if not self.options.debug:
+ self.options.debug = None
self.cloud = cc.get_one_cloud(
cloud=self.options.cloud,
argparse=self.options,
)
+ if self.options.debug is not None:
+ self.options.debug = False
self.log_configurator.configure(self.cloud)
self.dump_stack_trace = self.log_configurator.dump_trace