Edward Haas has uploaded a new change for review. Change subject: net libvirt hook: Adjust hook to vmList report change. ......................................................................
net libvirt hook: Adjust hook to vmList report change. Patch 78ea853e131da3b91b812315a0656b8f99d7fef4 has changed the output of vmList, from the key 'items' to 'vmList', breaking the hook. This patch adjusts the hook with the new key. Change-Id: I46925a65abc293e317b8df86bd958bf1cf27b6de Signed-off-by: Edward Haas <[email protected]> --- M tests/network/vm_migrate_hook_test.py M vdsm/virt/vm_migrate_hook.py 2 files changed, 2 insertions(+), 2 deletions(-) git pull ssh://gerrit.ovirt.org:29418/vdsm refs/changes/42/63542/1 diff --git a/tests/network/vm_migrate_hook_test.py b/tests/network/vm_migrate_hook_test.py index 7294734..7f11995 100644 --- a/tests/network/vm_migrate_hook_test.py +++ b/tests/network/vm_migrate_hook_test.py @@ -31,7 +31,7 @@ class MockVdscli(object): @staticmethod def fullList(*args, **kwargs): - return {'items': [VM_FULL_LIST]} + return {'vmList': [VM_FULL_LIST]} class MockJsonrpcvdscli(object): diff --git a/vdsm/virt/vm_migrate_hook.py b/vdsm/virt/vm_migrate_hook.py index 633e4f0..5379cef 100755 --- a/vdsm/virt/vm_migrate_hook.py +++ b/vdsm/virt/vm_migrate_hook.py @@ -179,7 +179,7 @@ def _vm_item(vdscli, vm_uuid): result = vdscli.fullList(fullStatus=True, vmList=(vm_uuid,)) - return result['items'][0] if len(result['items']) else None + return result['vmList'][0] if len(result['vmList']) else None def _vdscli(): -- To view, visit https://gerrit.ovirt.org/63542 To unsubscribe, visit https://gerrit.ovirt.org/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I46925a65abc293e317b8df86bd958bf1cf27b6de Gerrit-PatchSet: 1 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Edward Haas <[email protected]> _______________________________________________ vdsm-patches mailing list [email protected] https://lists.fedorahosted.org/admin/lists/[email protected]
