Fixed issues while using --bypass-url
Python-troveclient 1.0.8 introduced a regression where the usage of --bypass-url results in an AuthSystemNotFound exception. Removing some redundant code, which was due to a previous merge conflict, fixed the issue. Closes-bug 1416120 Change-Id: I1c949f69ee08447ce88aeefa92c60f361ab54832
This commit is contained in:
@@ -79,7 +79,7 @@ class HTTPClient(TroveClientMixin):
|
||||
http_log_debug=False, cacert=None, bypass_url=None,
|
||||
auth_system='keystone', auth_plugin=None):
|
||||
|
||||
if auth_system != 'keystone' and not auth_plugin:
|
||||
if auth_system and auth_system != 'keystone' and not auth_plugin:
|
||||
raise exceptions.AuthSystemNotFound(auth_system)
|
||||
|
||||
if not auth_url and auth_system and auth_system != 'keystone':
|
||||
@@ -92,14 +92,6 @@ class HTTPClient(TroveClientMixin):
|
||||
self.projectid = projectid
|
||||
self.tenant_id = tenant_id
|
||||
|
||||
if auth_system and auth_system != 'keystone' and not auth_plugin:
|
||||
raise exceptions.AuthSystemNotFound(auth_system)
|
||||
|
||||
if not auth_url and auth_system and auth_system != 'keystone':
|
||||
auth_url = auth_plugin.get_auth_url()
|
||||
if not auth_url:
|
||||
raise exceptions.EndpointNotFound()
|
||||
|
||||
self.auth_url = auth_url.rstrip('/') if auth_url else auth_url
|
||||
self.version = 'v1'
|
||||
self.region_name = region_name
|
||||
|
Reference in New Issue
Block a user