diff options
author | Gary Kotton <gkotton@vmware.com> | 2019-01-13 01:16:37 -0800 |
---|---|---|
committer | garyk <gkotton@vmware.com> | 2019-01-13 14:53:54 +0000 |
commit | 7180f1623259880437e81b8a2d56663cb6cb61e4 (patch) | |
tree | 6b417536336b50e043436a23b21b545648d7ba35 | |
parent | da98f4ba4554139b3901103aa0d26876b11e1d9a (diff) | |
download | nova-7180f1623259880437e81b8a2d56663cb6cb61e4.tar.gz |
Enhance exception raised when invalid power state
The invalid state exception did not pass wht power state
as a string. Ensure that it is a string and not an integer.
TrivialFix
Change-Id: I37bb05585bc16de14f7e9a2eb3864c5ed90c7603
Closes-bug: #1811565
-rw-r--r-- | nova/conductor/tasks/live_migrate.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/nova/conductor/tasks/live_migrate.py b/nova/conductor/tasks/live_migrate.py index 9ee86c08be..0ba59add7e 100644 --- a/nova/conductor/tasks/live_migrate.py +++ b/nova/conductor/tasks/live_migrate.py @@ -149,7 +149,7 @@ class LiveMigrationTask(base.TaskBase): raise exception.InstanceInvalidState( instance_uuid=self.instance.uuid, attr='power_state', - state=self.instance.power_state, + state=power_state.STATE_MAP[self.instance.power_state], method='live migrate') def _check_instance_has_no_numa(self): |