diff options
| author | Chuck Short <chuck.short@canonical.com> | 2013-06-19 20:46:46 -0500 |
|---|---|---|
| committer | Chuck Short <chuck.short@canonical.com> | 2013-06-19 20:52:22 -0500 |
| commit | 3044671b3647cd9a6b14b6262baa44567c6e995b (patch) | |
| tree | 635e243e2c42b8396c2e02e2b40ad3d40ecad42a /cinderclient/shell.py | |
| parent | 89fb1503e91ae6485058659086f46a1dc0454f07 (diff) | |
| download | python-cinderclient-3044671b3647cd9a6b14b6262baa44567c6e995b.tar.gz | |
python3: Fix traceback while running tests
The testsuite is full of the following:
TypeError: 'dict_keys' object does not support indexing
This is due to the fact in python3 dict methods dict.keys(),
dict.items() and dict.values() return “views” instead of lists.
Change-Id: Ifa5383e6485fdbabf363fd1442877b2452346c1c
Signed-off-by: Chuck Short <chuck.short@canonical.com>
Diffstat (limited to 'cinderclient/shell.py')
| -rw-r--r-- | cinderclient/shell.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/cinderclient/shell.py b/cinderclient/shell.py index 9d4af09..9750d2f 100644 --- a/cinderclient/shell.py +++ b/cinderclient/shell.py @@ -465,9 +465,9 @@ class OpenStackCinderShell(object): """ commands = set() options = set() - for sc_str, sc in self.subcommands.items(): + for sc_str, sc in list(self.subcommands.items()): commands.add(sc_str) - for option in sc._optionals._option_string_actions.keys(): + for option in list(sc._optionals._option_string_actions.keys()): options.add(option) commands.remove('bash-completion') |
