From mboxrd@z Thu Jan 1 00:00:00 1970 From: Philipp Hahn Subject: Re: [BUG, PATCH] xen-4.1-3 xend/XendDomainInfo.py#device_configure() TypeError Date: Wed, 29 May 2013 07:47:11 +0200 Message-ID: <201305290747.11406.hahn@univention.de> References: <201305241953.10495.hahn@univention.de> <20130528152552.GA4695@phenom.dumpdata.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <20130528152552.GA4695@phenom.dumpdata.com> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: Konrad Rzeszutek Wilk , xen-devel List-Id: xen-devel@lists.xenproject.org Hello, Am Dienstag 28 Mai 2013, 17:25:52 schrieben Sie: > > def _getDeviceInfo_vbd(self, devid): > > for dev_type, dev_info in self.info.all_devices_sxpr() ... > > return dev_info > > Ewwww, that looks buggy. Could you just do 'return dev' ? I don't think that this would be correct, since dev and devid are just the device numbers, but dev_info contains the device details as an Sxpr: devid='768' dev='hda:cdrom' ... dev='hda' ... dev=768 dev_type='vbd' dev_info=['vbd', ('uuid', '920a5c24-28c6-6abb-ad47-9c1144012986'), ('bootable', 1), ('driver', 'paravirtualised'), ('dev', 'hda:cdrom'), ('uname', 'file:/var/lib/libvirt/images/UCS_3.1-1-amd64.iso'), ('mode', 'r'), ('VDI', ''), ('backend', 0)] So chaning the return type of the function with the name _get*DeviceInfo* look wrong. Or am I missing something? Sincerely Philipp -- Philipp Hahn Open Source Software Engineer hahn@univention.de Univention GmbH be open. fon: +49 421 22 232- 0 Mary-Somerville-Str.1 D-28359 Bremen fax: +49 421 22 232-99 http://www.univention.de/