[xml/sgml-pkgs] Bug#832602: [libxml2] Schema validation with attribute checks fails (upstream #766834)
Andre Naujoks
nautsch2 at gmail.com
Wed Jul 27 12:13:16 UTC 2016
Package: libxml2
Version: 2.9.4+dfsg1-1
Severity: important
--- Please enter the report below this line. ---
XML Schema validation fails, when attribute values are checked against a
pattern or otherwise non-empty attributes would not validate.
Attached are a very simple schema and an XML file, which validates with
2.9.3 but not with 2.9.4
The generated errors are:
# xmlstarlet val -e -s test.xsd test.xml
test.xml:1.18: Element 'Test', attribute 'test': [facet 'pattern'] The
value '' is not accepted by the pattern '.+'.
test.xml:1.18: Element 'Test', attribute 'test': '' is not a valid value
of the atomic type 'mytype'.
test.xml - invalid
The bug is known upstream: https://bugzilla.gnome.org/show_bug.cgi?id=766834
A patch is available there, too. The patch solves the problem.
I am not attaching the patch, because I did not write it.
There is a mailing-list thread, which mentions the patch and why it is
not yet applied, and it seems they are waiting for a review by the
author of libxml2, which did not happen until now.
https://mail.gnome.org/archives/xml/2016-June/msg00003.html
I'd like to ask, if Debian could carry the patch from the upstream
bug-tracker until it lands upstream and a new version is released,
because this bug breaks basically all schema validation, that is not
trivial.
Regards
Andre
--- System information. ---
Architecture: amd64
Kernel: Linux 4.6.0-1-amd64
Debian Release: stretch/sid
500 unstable ftp.de.debian.org 500 testing
ftp.de.debian.org 1 experimental ftp.de.debian.org
--- Package information. ---
Depends (Version) | Installed
=====================================-+-=========================
libc6 (>= 2.15) | libicu55 (>=
55.1-1~) | liblzma5 (>= 5.1.1alpha+20120614) | zlib1g
(>= 1:1.2.3.3) |
Recommends (Version) | Installed
=========================-+-===========
xml-core | 0.13+nmu2
Package's Suggests field is empty.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: test.xml
Type: text/xml
Size: 20 bytes
Desc: not available
URL: <http://lists.alioth.debian.org/pipermail/debian-xml-sgml-pkgs/attachments/20160727/3c8e2967/attachment.xml>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: test.xsd
Type: application/xml
Size: 447 bytes
Desc: not available
URL: <http://lists.alioth.debian.org/pipermail/debian-xml-sgml-pkgs/attachments/20160727/3c8e2967/attachment.xsd>
More information about the debian-xml-sgml-pkgs
mailing list