Re: [xml] libxslt test suite broken by recent libxml2 commit



On Sun, Sep 28, 2014 at 03:36:15PM +0200, Nick Wellnhofer wrote:
Some further notes:

First of all, I wonder why I get the warning without the --valid option.

This is because some ID checks are made regardless of the --valid option. Makes sense.

Second, I can’t see why the id attribute would be already defined.

This is because an external entity is parsed using the original document as context doc:

    https://git.gnome.org/browse/libxml2/tree/parser.c?id=33f658c969501bb246f8d4c6d21772948c7bc965#n12987

Then, when entities are replaced, the ID values have already been added to the doc. This should probably be 
fixed in libxml2 but I’m not sure what’s the best approach.

The other issue in the libxslt test suite is that the HTML docbook tests actually create documents with 
duplicate “name” attributes which are treated as IDs in HTML documents. This might be fixed in a newer 
version of docbook-xsl. But the easiest fix for now is to simply add the warning messages to the expected 
test output.

  Yes, libxml2 ought to raise the error (non-fatal obviously), and I
agree that's a case where the test data need to be modified to cope with
it,

  thanks for raising this !

Daniel

-- 
Daniel Veillard      | Open Source and Standards, Red Hat
veillard redhat com  | libxml Gnome XML XSLT toolkit  http://xmlsoft.org/
http://veillard.com/ | virtualization library  http://libvirt.org/


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]