summaryrefslogtreecommitdiff
path: root/openstackclient
diff options
context:
space:
mode:
authorAndreas Florath <Andreas.Florath@telekom.de>2019-09-19 11:44:14 +0000
committerAndreas Florath <Andreas.Florath@telekom.de>2019-09-19 11:59:11 +0000
commit9ad343968947fc025b530644c3369c60a2c14ea5 (patch)
treeb0a9ba69ab7e12fc6d3a4293d49f7a96f71c8751 /openstackclient
parentaa64eb6b0acc6e049c81fd856b75cda2f905c84c (diff)
downloadpython-openstackclient-9ad343968947fc025b530644c3369c60a2c14ea5.tar.gz
Fix osc-lib interface change: catch osc-lib Forbidden
The patch https://review.opendev.org/#/c/673389/ introduced a regression by changing the osc-lib interface. The patch https://review.opendev.org/683119 changes the exception from the generic CommandError back to a specific Forbidden exception. This patch catches this exception and passes on, i.e. re-implements the same behavior as before. Story: 2006547 Change-Id: I17b1ec7abaa5b0828ccbcad40bd928565c5c59fb Signed-off-by: Andreas Florath <Andreas.Florath@telekom.de>
Diffstat (limited to 'openstackclient')
-rw-r--r--openstackclient/identity/common.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/openstackclient/identity/common.py b/openstackclient/identity/common.py
index e8251166..d125d285 100644
--- a/openstackclient/identity/common.py
+++ b/openstackclient/identity/common.py
@@ -207,7 +207,7 @@ def _find_identity_resource(identity_client_manager, name_or_id,
name_or_id, **kwargs)
if identity_resource is not None:
return identity_resource
- except identity_exc.Forbidden:
+ except exceptions.Forbidden:
pass
return resource_type(None, {'id': name_or_id, 'name': name_or_id})