commit 62fbfdfa8f2dda1a5d9c3733b2f3da3a9d00c93a
Author: Matt Riedemann <email address hidden>
Date: Wed Oct 10 15:07:00 2018 -0400
Fix NoneType error in _notify_volume_usage_detach
If the driver.block_stats() method returns None, like the
libvirt driver will if the guest is gone during an evacuate,
we'll get a NoneType error trying to unpack the return value
from the driver. Instead, simply return as if the driver
raised NotImplementedError.
Since handling None is changing the contract on the virt
driver API, the docstring is updated to explain the acceptable
return values of the driver method.
Change-Id: I98a2785c07f7af02ad83650c72d9e1868290ece4
Closes-Bug: #1796981
(cherry picked from commit 4da54c07861a1542a8e30a768d4506d3e81b5598)
(cherry picked from commit 940034c27c611b8b344f8371eb0458b16fb58f1d)
Reviewed: https:/ /review. openstack. org/614868 /git.openstack. org/cgit/ openstack/ nova/commit/ ?id=62fbfdfa8f2 dda1a5d9c3733b2 f3da3a9d00c93a
Committed: https:/
Submitter: Zuul
Branch: stable/queens
commit 62fbfdfa8f2dda1 a5d9c3733b2f3da 3a9d00c93a
Author: Matt Riedemann <email address hidden>
Date: Wed Oct 10 15:07:00 2018 -0400
Fix NoneType error in _notify_ volume_ usage_detach
If the driver. block_stats( ) method returns None, like the rror.
libvirt driver will if the guest is gone during an evacuate,
we'll get a NoneType error trying to unpack the return value
from the driver. Instead, simply return as if the driver
raised NotImplementedE
Since handling None is changing the contract on the virt
driver API, the docstring is updated to explain the acceptable
return values of the driver method.
Change-Id: I98a2785c07f7af 02ad83650c72d9e 1868290ece4 2a8e30a768d4506 d3e81b5598) b344f8371eb0458 b16fb58f1d)
Closes-Bug: #1796981
(cherry picked from commit 4da54c07861a154
(cherry picked from commit 940034c27c611b8