Exception type is not iterable so should change it to string type

This is to use string type for exception messages.

Change-Id: I78d204fecd52c5c43b0b4685c07aedbe74710f4a
This commit is contained in:
zhufl 2020-11-27 14:21:33 +08:00
parent be9008bc9e
commit 0a11cac112

View File

@ -723,7 +723,7 @@ class PowerMaxProvision(object):
array, source_device_id, "", snap_name, extra_specs,
snap_id=snap_id, restore=True)
except exception.VolumeBackendAPIException as ex:
if utils.REVERT_SS_EXC in ex:
if utils.REVERT_SS_EXC in str(ex):
exception_message = _(
"Link must be fully copied for this operation to proceed. "
"Please reset the volume state from error to available "