[issue19832] XML version is ignored

Tobias Kuhn report at bugs.python.org
Fri Nov 29 14:33:09 CET 2013


New submission from Tobias Kuhn:

The first line of an XML file should be something like this:

    <?xml version='1.0' encoding='UTF-8'?>

The XML parser of xml.sax, however, seems to ignore the value of "version":

    <?xml version='X' encoding='UTF-8'?>

This should give an error, but it doesn't. It's not a very serious problem, but this should raise an error to be standards-compliant.

I experienced this bug in the rdflib package:

    https://github.com/RDFLib/rdflib/issues/347

----------
components: XML
messages: 204720
nosy: tkuhn
priority: normal
severity: normal
status: open
title: XML version is ignored
type: behavior
versions: Python 2.7

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue19832>
_______________________________________


More information about the Python-bugs-list mailing list