Bug 1058403

Summary: javapackages-tools: regression in %pom_xpath_remove
Product: [Fedora] Fedora Reporter: Mikolaj Izdebski <mizdebsk>
Component: javapackages-toolsAssignee: Mikolaj Izdebski <mizdebsk>
Status: CLOSED CURRENTRELEASE QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 21CC: java-sig-commits, mizdebsk, msimacek, msrb, sochotni
Target Milestone: ---Keywords: Upstream, VerifiedUpstream
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: 4.1.0-2 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2014-07-16 12:38:28 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Mikolaj Izdebski 2014-01-27 17:49:54 UTC
Download http://git.eclipse.org/c/jetty/org.eclipse.jetty.project.git/snapshot/jetty-8.1.14.v20131031.tar.bz2 and take the main pom.xml

run %pom_xpath_remove "pom:modules/node()"

+ python /usr/share/java-utils/pom_editor.py pom_xpath_remove 'pom:modules/node()'
Traceback (most recent call last):
  File "/usr/share/java-utils/pom_editor.py", line 356, in <module>
     macros[sys.argv[1]](*sys.argv[2:])
  File "/usr/share/java-utils/pom_editor.py", line 98, in decorated
     function(*fnargs)
  File "/usr/share/java-utils/pom_editor.py", line 258, in pom_xpath_remove
     pom.replace_xml(element, "<!-- element removed by maintainer -->")
  File "/usr/share/java-utils/pom_editor.py", line 145, in replace_xml
     idx = parent.index(replaced)
TypeError :  Argument 'child' has incorrect type (expected lxml.etree._Element, got _ElementStringResult) 

The same call works with pom_editor.sh.

Version:
javapackages-tools-3.6.0-0.2.gitd370124.noarch

Comment 1 Michael Simacek 2014-01-29 09:59:56 UTC
Should be fixed in upstream commit 5eb4ce0

Comment 2 Mikolaj Izdebski 2014-02-03 14:30:34 UTC
Verified upstream.

Comment 3 Fedora Admin XMLRPC Client 2014-04-24 12:47:17 UTC
This package has changed ownership in the Fedora Package Database.  Reassigning to the new owner of this component.

Comment 4 Mikolaj Izdebski 2014-07-16 12:38:28 UTC
I believe that this bug is fixed in javapackages-tools-4.1.0-2,
which is available in Fedora 21, so I am closing this bug now.

The build containing the fix can be found at Koji:
http://koji.fedoraproject.org/koji/buildinfo?buildID=543061