Comment 1 for bug 1629331

Revision history for this message
Matthew Edmonds (edmondsw) wrote :

I think this may actually be an openstacksdk bug. I was able to get os_client_config.config.get_one_cloud working like this:

cloud_config = os_client_config.OpenStackConfig()
parser = argparse.ArgumentParser()
cloud_config.register_argparse_arguments(parser, sys.argv[1:])
options = parser.parse_args()
cloud = cloud_config.get_one_cloud(argparse=options)

whereas openstacksdk is just passing the ArgumentParser() instance without calling register_argparse_arguments or parse_args