Browse Source

Fix pep8 F821 error

Change-Id: Idef9c90b57b67fae2e896de00cc8f647c238cae8
zhurong 3 months ago
parent
commit
95f9da9cd8

+ 2
- 2
murano/dsl/murano_type.py View File

@@ -280,9 +280,9 @@ class MuranoClass(dsl_types.MuranoClass, MuranoType, dslmeta.MetaProvider):
280 280
         for name in self.all_method_names:
281 281
             try:
282 282
                 yield self.find_single_method(name)
283
-            except exceptions.AmbiguousMethodName as e:
283
+            except exceptions.AmbiguousMethodName:
284 284
                 def func(*args, **kwargs):
285
-                    raise e
285
+                    raise
286 286
                 yield murano_method.MuranoMethod(
287 287
                     self, name, func, ephemeral=True)
288 288
 

+ 1
- 1
murano/engine/system/workflowclient.py View File

@@ -53,7 +53,7 @@ class MistralClient(object):
53 53
     def _create_client(region):
54 54
         if not mistralcli:
55 55
             LOG.warning("Mistral client is not available")
56
-            raise mistral_import_error
56
+            raise ImportError("Import mistralcliet error")
57 57
 
58 58
         mistral_settings = CONF.mistral
59 59
 

+ 1
- 1
murano/policy/model_policy_enforcer.py View File

@@ -54,7 +54,7 @@ class ModelPolicyEnforcer(object):
54 54
     def _create_client(self):
55 55
         if not congress_client:
56 56
             # congress client was not imported
57
-            raise congress_client_import_error
57
+            raise ImportError("Import congresscliet error")
58 58
         return congress_client.Client(
59 59
             **auth_utils.get_session_client_parameters(
60 60
                 service_type='policy',

Loading…
Cancel
Save