Bug 844533 - Work on removing PyXML dependency
Work on removing PyXML dependency
Status: CLOSED CURRENTRELEASE
Product: Fedora
Classification: Fedora
Component: spacewalk-backend (Show other bugs)
19
Unspecified Unspecified
unspecified Severity unspecified
: ---
: ---
Assigned To: Miroslav Suchý
Fedora Extras Quality Assurance
:
Depends On:
Blocks: 843176 844603
  Show dependency treegraph
 
Reported: 2012-07-30 22:48 EDT by Toshio Ernie Kuratomi
Modified: 2015-01-14 08:48 EST (History)
1 user (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
: 844603 (view as bug list)
Environment:
Last Closed: 2015-01-14 08:48:15 EST
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Toshio Ernie Kuratomi 2012-07-30 22:48:17 EDT
Description of problem:

For Fedora 18 we're trying to get rid of PyXML in the distribution[1]_.  The reason is that PyXML has been dead upstream for a long time and it has the dubious behaviour of overwriting the python stdlib's xml module with its own code.  The combination of these two means that code that uses the stdlib's xml module can sometimes be broken by installing the PyXML package (because of old bugs or old code in PyXML that hasn't been ported to newer python versions).

I've taken a look at spacewalk-backend-tools which has a Requires: PyXML and found two places that PyXML/the stdlib xml module is used, both in unittests:

./satellite_tools/test/testxmlparser.py:from xml.sax import make_parser, saxutils
./satellite_tools/test/testxmlparser.py:from xml.sax.handler import feature_namespaces
./satellite_tools/test/testxmlparser.py:from xml.unicode.utf8_iso import utf8_to_code

./satellite_tools/test/testxmlwriter.py:from xml.sax.saxutils import escape
./satellite_tools/test/testxmlwriter.py:from xml.unicode.utf8_iso import code_to_utf8
./satellite_tools/test/testxmlwriter.py:import xml.sax.writer

Of these, most of the API being used is present in stdlib xml module (but I don't know if the behaviour matches).  Only unicode.utf8_iso.* and xml.sax.writer are not present.

Looking at ./satellite_tools/test/testxmlwriter.py, I'm not sure that this file is even testing any code in satellite/spacewalk.  It doesn't import any spacewalk code.  It does write an xml file that may be used by some other tests.  However, I can't find any file that invokes it and in addition, it doesn't appear to be runnable:

python testxmlwriter.py
  File "testxmlwriter.py", line 65
SyntaxError: Non-ASCII character '\xa9' in file testxmlwriter.py on line 65, but no encoding declared; see http://www.python.org/peps/pep-0263.html for details

./satellite_tools/test/testxmlparser.py also doesn't look like it is testing any sattellite/spacewalk code.  If necessary, it's use of utf8_to_code looks like it may be possible to port to something from http://packages.python.org/kitchen/api-text-converters.html#transformation-to-xml

So.  Are these unittest files being used or can they simply be discarded?  If they are used, can we port them away from PyXML so that we can get rid of that dependency?

.. [1]: https://fedoraproject.org/wiki/User:Toshio/Remove_PyXML
Comment 1 Miroslav Suchý 2012-07-31 03:26:30 EDT
Cloned to upstream as bug 844603.
Comment 2 Toshio Ernie Kuratomi 2013-01-11 14:49:26 EST
Glad to see the fix has gone in upstream.  I've created a Fedora 19 Feature for removing PyXML from Fedora.  What are your plans for getting the changes into our package?  Are you going to put the new version in Fedora 19?  Or do you need me to look at backporting the change to the F19 package?
Comment 3 Miroslav Suchý 2013-01-14 04:02:52 EST
Next version of Spacewalk should be released in 3 weeks.
https://fedorahosted.org/spacewalk/milestone/1.9
I will then build new packages into F19.
Comment 4 Fedora End Of Life 2013-04-03 16:20:26 EDT
This bug appears to have been reported against 'rawhide' during the Fedora 19 development cycle.
Changing version to '19'.

(As we did not run this process for some time, it could affect also pre-Fedora 19 development
cycle bugs. We are very sorry. It will help us with cleanup during Fedora 19 End Of Life. Thank you.)

More information and reason for this action is here:
https://fedoraproject.org/wiki/BugZappers/HouseKeeping/Fedora19
Comment 5 Fedora End Of Life 2015-01-09 17:26:05 EST
This message is a notice that Fedora 19 is now at end of life. Fedora 
has stopped maintaining and issuing updates for Fedora 19. It is 
Fedora's policy to close all bug reports from releases that are no 
longer maintained. Approximately 4 (four) weeks from now this bug will
be closed as EOL if it remains open with a Fedora 'version' of '19'.

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.

Thank you for reporting this issue and we are sorry that we were not 
able to fix it before Fedora 19 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, you are encouraged  change the 'version' to a later Fedora 
version prior this bug is closed as described in the policy above.

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.
Comment 6 Miroslav Suchý 2015-01-14 08:48:15 EST
this should be fixed now

Note You need to log in before you can comment on or make changes to this bug.