[Kimchi-devel] [PATCH] [Kimchi] Bug fix #1057: Failed to import kimchi

Aline Manera alinefm at linux.vnet.ibm.com
Tue Dec 13 15:10:23 UTC 2016


Hi Bianca,

I could not apply this patch on stable branch. Could you rebase and resend?

BTW, It works on master branch but it would be good to have it for 2.3.1 
release.

On 12/12/2016 12:14 PM, bianca at linux.vnet.ibm.com wrote:
> From: Bianca Carvalho <bianca at linux.vnet.ibm.com>
>
> Changed "registerAttachDevicesEvent" in model/libvirtevents.py file
> to include AttributeError as a exception to make sure kimchi will
> be running even if this exception is true.
> Also fixed indentation in vms.py file.
>
> Signed-off-by: Bianca Carvalho <bianca at linux.vnet.ibm.com>
> ---
>   model/libvirtevents.py | 2 +-
>   model/vms.py           | 2 +-
>   2 files changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/model/libvirtevents.py b/model/libvirtevents.py
> index 2dd9904..716420c 100644
> --- a/model/libvirtevents.py
> +++ b/model/libvirtevents.py
> @@ -101,7 +101,7 @@ class LibvirtEvents(object):
>                   cb,
>                   arg)
>
> -        except libvirt.libvirtError as e:
> +        except (AttributeError, libvirt.libvirtError), e:
>               wok_log.error("register attach event failed: %s" % e.message)
>
>       def registerDetachDevicesEvent(self, conn, cb, arg):
> diff --git a/model/vms.py b/model/vms.py
> index d703c89..d6f8020 100644
> --- a/model/vms.py
> +++ b/model/vms.py
> @@ -1108,7 +1108,7 @@ class VMModel(object):
>
>       def update_cpu_live(self, dom, vcpus):
>           flags = libvirt.VIR_DOMAIN_AFFECT_LIVE | \
> -                libvirt.VIR_DOMAIN_AFFECT_CONFIG
> +            libvirt.VIR_DOMAIN_AFFECT_CONFIG
>           try:
>               dom.setVcpusFlags(vcpus, flags)
>           except libvirt.libvirtError as e:




More information about the Kimchi-devel mailing list