Merge "Fixes hpelefthandclient AttributeError"
This commit is contained in:
commit
2ee3aa1d76
@ -329,6 +329,14 @@ class HPELeftHandISCSIDriver(driver.ISCSIDriver):
|
|||||||
|
|
||||||
def do_setup(self, context):
|
def do_setup(self, context):
|
||||||
"""Set up LeftHand client."""
|
"""Set up LeftHand client."""
|
||||||
|
if not hpelefthandclient:
|
||||||
|
# Checks if client was successfully imported
|
||||||
|
ex_msg = (_("HPELeftHand client is not installed. Please"
|
||||||
|
" install using 'pip install "
|
||||||
|
"python-lefthandclient'."))
|
||||||
|
LOG.error(ex_msg)
|
||||||
|
raise exception.VolumeDriverException(ex_msg)
|
||||||
|
|
||||||
if hpelefthandclient.version < MIN_CLIENT_VERSION:
|
if hpelefthandclient.version < MIN_CLIENT_VERSION:
|
||||||
ex_msg = (_("Invalid hpelefthandclient version found ("
|
ex_msg = (_("Invalid hpelefthandclient version found ("
|
||||||
"%(found)s). Version %(minimum)s or greater "
|
"%(found)s). Version %(minimum)s or greater "
|
||||||
|
Loading…
x
Reference in New Issue
Block a user