Comment 3 for bug 1839185

Revision history for this message
Tedd Terry (tterry) wrote :

Sorry, my mistake, I messed up the input while trying to trim it down for a repro case.

There is definitely a bug (or unexpected change in behavior) that reproduces with lxml 4.4.0 and not lxml 4.3.5 or earlier.

Please find updated well formed XML with the same issue which caused XML parsed with lxml 4.4.0 to be rejected by a .NET service further down the line. Again, note the colon in the declaration of the xmlns attribute of the NAMM_PO element:

Input 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>

Output XML (lxml 4.4.0):
<?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>

Output XML (lxml 4.3.5):
<?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>