Bug 601464

Summary: duplicate function name createXML() in the libvirt.py
Product: [Fedora] Fedora Reporter: Nan Zhang <nzhang>
Component: libvirtAssignee: Daniel Veillard <veillard>
Status: CLOSED CURRENTRELEASE QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: high Docs Contact:
Priority: low    
Version: 12CC: berrange, clalance, crobinso, itamar, jforbes, llim, veillard, virt-maint, xen-maint
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Linux   
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2010-11-17 14:00:10 EST Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Description Nan Zhang 2010-06-07 23:02:55 EDT
Description of problem:
In module /usr/lib64/python2.6/site-packages/libvirt.py, there are two methods having the same name createXML() in the virConnect Class. It makes confused to invoke the related function.

Version-Release number of selected component (if applicable):

How reproducible:

Steps to Reproduce:
    def createXML(self, xmlDesc, flags):
        """Create a new device on the VM host machine, for example,
           virtual HBAs created using vport_create. """
        ret = libvirtmod.virNodeDeviceCreateXML(self._o, xmlDesc, flags)
        if ret is None:raise libvirtError('virNodeDeviceCreateXML() failed', conn=self)
        __tmp = virNodeDevice(self, _obj=ret)
        return __tmp

    def createXML(self, xmlDesc, flags):
        """Launch a new guest domain, based on an XML description
          similar to the one returned by virDomainGetXMLDesc() This
          function may requires privileged access to the hypervisor.
          The domain is not persistent, so its definition will
          disappear when it is destroyed, or if the host is restarted
           (see virDomainDefineXML() to define persistent domains). """
        ret = libvirtmod.virDomainCreateXML(self._o, xmlDesc, flags)
        if ret is None:raise libvirtError('virDomainCreateXML() failed', conn=self)
        __tmp = virDomain(self,_obj=ret)
        return __tmp
Actual results:
Failed to invoke virNodeDeviceCreateXML().

Expected results:
Different function name.

Additional info:
Comment 2 Nan Zhang 2010-06-07 23:17:33 EDT
Sorry, actually this code is come from fedora package. Move to Fedora product.
Comment 3 Nan Zhang 2010-06-07 23:18:41 EDT
Comment 4 Bug Zapper 2010-11-03 09:27:45 EDT
This message is a reminder that Fedora 12 is nearing its end of life.
Approximately 30 (thirty) days from now Fedora will stop maintaining
and issuing updates for Fedora 12.  It is Fedora's policy to close all
bug reports from releases that are no longer maintained.  At that time
this bug will be closed as WONTFIX if it remains open with a Fedora 
'version' of '12'.

Package Maintainer: If you wish for this bug to remain open because you
plan to fix it in a currently maintained version, simply change the 'version' 
to a later Fedora version prior to Fedora 12's end of life.

Bug Reporter: Thank you for reporting this issue and we are sorry that 
we may not be able to fix it before Fedora 12 is end of life.  If you 
would still like to see this bug fixed and are able to reproduce it 
against a later version of Fedora please change the 'version' of this 
bug to the applicable version.  If you are unable to change the version, 
please add a comment here and someone will do it for you.

Although we aim to fix as many bugs as possible during every release's 
lifetime, sometimes those efforts are overtaken by events.  Often a 
more recent Fedora release includes newer upstream software that fixes 
bugs or makes them obsolete.

The process we are following is described here: 
Comment 5 Nan Zhang 2010-11-03 23:18:33 EDT
One of the function name is renamed with nodeDeviceCreateXML(). So this bug was already fixed with libvirt-0.8.2-1.fc12.i686. Move it to VERIFIED.
Comment 6 Cole Robinson 2010-11-17 14:00:10 EST
Closing as per comment #5