[Bug 1839185] [NEW] element with xmlns attribute is not rendered properly

Launchpad Bug Tracker 1839185 at bugs.launchpad.net
Mon Mar 21 11:33:31 UTC 2022


You have been subscribed to a public bug:

lxml 4.4.0 introduces an issue with the following XML:

<?xml version="1.0" encoding="utf-8"?>
<NAMM_PO version="2009.2" xmlns="http://namm.com/PO/2009.2">
<Id>TEST_ID</Id>
<NAMM_PO>

This is the output XML:

<?xml version="1.0" encoding="utf-8"?>
<NAMM_PO version="2009.2" xmlns:="http://namm.com/PO/2009.2">
<Id>TEST_ID</Id>
<NAMM_PO/></NAMM_PO>

Note the missing closing tag of the NAMM_PO element, the additional
NAMM_PO element, and the addition of a colon to the xmlns attribute.

Version info:

Python              : sys.version_info(major=2, minor=7, micro=10, releaselevel='final', serial=0)
lxml.etree          : (4, 4, 0, 0)
libxml used         : (2, 9, 9)
libxml compiled     : (2, 9, 9)
libxslt used        : (1, 1, 33)
libxslt compiled    : (1, 1, 33)

To repro:

Open and unarchive attached 'lxml_4_4_0_bug.zip'.  Create a virtual
environment, install requirements, and run 'python repro.py' to produce
the above output.

** Affects: lxml (Ubuntu)
     Importance: Undecided
         Status: Fix Released

** Affects: beautifulsoup4 (Ubuntu)
     Importance: Undecided
         Status: Fix Released

-- 
element with xmlns attribute is not rendered properly
https://bugs.launchpad.net/bugs/1839185
You received this bug notification because you are a member of Ubuntu Foundations Bugs, which is subscribed to lxml in Ubuntu.



More information about the foundations-bugs mailing list