Skip to content

Commit 8f07476

Browse files
Zuulopenstack-gerrit
authored andcommitted
Merge "volume list: don't fail when there's no compute service"
2 parents fe165ef + 077c9a7 commit 8f07476

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

openstackclient/volume/v2/volume.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -361,7 +361,6 @@ def get_parser(self, prog_name):
361361
def take_action(self, parsed_args):
362362

363363
volume_client = self.app.client_manager.volume
364-
compute_client = self.app.client_manager.compute
365364
identity_client = self.app.client_manager.identity
366365

367366
if parsed_args.long:
@@ -393,6 +392,7 @@ def take_action(self, parsed_args):
393392
# Cache the server list
394393
server_cache = {}
395394
try:
395+
compute_client = self.app.client_manager.compute
396396
for s in compute_client.servers.list():
397397
server_cache[s.id] = s
398398
except Exception:

0 commit comments

Comments
 (0)