Issue Details (XML | Word | Printable)

Key: OFFICE-2203
Type: Bug Bug
Status: Applied Applied
Resolution: Fixed
Priority: Major Major
Assignee: Svante Schubert
Reporter: Robert Weir
Watchers: 0
Operations

If you were logged in you would be able to see more operations.
OASIS Open Document Format for Office Applications (OpenDocument) TC

Validation concerns [N 1309:6]

Created: 09/Nov/09 11:47 AM   Updated: 05/Nov/10 11:17 PM
Component/s: Conformance
Affects Version/s: ODF 1.0
Fix Version/s: ODF 1.0 Errata CD 5

Environment: This issue remains applicable to Errata 01 CD04

Proposal: Research the rules for validation that is explicitly stated for XML Documents consumed by ODF processors and determine whether there is anything to be addressed with regard to DTD processing and how it influences the XML.
Resolution:
2.1.2 Document Root Attributes
Delete:
"If the file has a version known to an XML processor, it may validate the document. Otherwise, it is optional to validate the document, but the document must be well formed."


 Description  « Hide
Submitter ID
    GB-26300-38
Nature of defect
    Technical
Document
    ISO/IEC 26300:2006
Clause
    2.1.2
Page
    38
Description of issue

It is stated that:

    The version number is in the format revision.version. If the file has a version known to an XML processor, it may validate the document. Otherwise, it is optional to validate the document, but the document must be well formed.

However:

    * No "XML Processor" has an understanding of such attributes. Perhaps what is meant here is "ODF processor"?
    * There is a false opposition between the two given behaviours here since one is governed by the word "may" and the other is described as optional. So as stated, both behaviours are in fact optional; furthermore there is an implication that a document with an unrecognized version attribute may not be well-formed. This is confusing.
    * DTD-governed MathML content within ODF documents may have different content depending on how the DTD is processed, since the DTD contains attribute defaulting; so the different behaviours given here may result in different documents. The behaviour in such circumstances should be clarified (even if to state it is application-dependent).

Proposal

Amend the text to resolve the above defects.



 All   Comments   Change History      Sort Order: Ascending order - Click to sort in descending order
Michael Brauer added a comment - 06/Jan/10 04:52 AM
Alex is right. Instead of "XML processor" it must read ODF processor". But regardless of that, it is optional to validate the document. My suggestion is to simply remove the 2nd sentence of the paragraph.

Dennis Hamilton added a comment - 17/Mar/10 07:41 PM
The second part of this defect item is not addressed. It is not mentioned in the Errata 01 CD04 Public Review draft that this part of the defect item is not addressed:

* DTD-governed MathML content within ODF documents may have different content depending on how the DTD is processed, since the DTD contains attribute defaulting; so the different behaviours given here may result in different documents. The behaviour in such circumstances should be clarified (even if to state it is application-dependent).

It *may* be that the rules for what kind of validation an ODF processor shall perform with XML documents covers this case, but there should be an indication if that is or is not the case.

Svante Schubert added a comment - 24/Apr/10 03:56 PM
The mathml DTD referenced http://www.w3.org/TR/2003/REC-MathML2-20031021/appendixa.html#parsing.dtd does indeed declare default values as 10 for the mathematical base.

It is correct that a MathML application is not enforced to read the DTD with the default values. Only that the DTD does not have to be read does not realease the application to use the default values defined by the DTD. These values might as well be hard wired into the application.
Otherwise the mathematical document (e.g. equatiations) would get corrupted.

Finally, MathML as well does not state that documents might be different, if the DTD was read or not.
If it is an issue at all it would belong to the MathML group.

Dennis Hamilton added a comment - 04/Jun/10 11:06 PM - edited
I'm not sure I understand the observation about MathML. In ODF 1.0, there is no described MathML root element (although that is cleared up somewhat in ODF 1.2 for a package consisting of an OpenFormula Formula Document.

On the other hand, there is a general matter with regard to the specification of attribute values in an internal subset DTD. That seems particularly difficult to handle unless the prefix with namespace binding to <math:math> and others are known, and the non-validating process is properly forgiving if all element types are not defined.

I can see entity values being defined that could be used in attribute values to set options globally (as well as create named character entities).

However, it is incorrect that the DTD does not have to be read. An internal subset DTD must be read and the definitions that don't require reading of an external entity must be processed (with some adjustment for any standalone setting in the XML prolog).

There needs to be some sort of clear resolution of whether the second part is applicable or not.


Dennis Hamilton added a comment - 04/Jun/10 11:59 PM
I just gave ODF 1.0 a pretty good scan, and I can't find any place where, for 1.0, we say that the XML must be handled with a non-validating processor.

That means the DTD situation is more complicated. However, even if the XML prolog has standalone="yes" a DTD internal subset must still be processed. By excluding any references to external entities or any DTD external subset, it is possible to introduce attribute default values a couple of ways, including by use of global entity definitions.

I just don't see how that has anything to do with the substance of ODF 1.0 section 2.1.2.

Anyone else have a clue?

Dennis Hamilton added a comment - 05/Nov/10 11:17 PM
ODF 1.2 has no counterpart of the deleted statement so there is no transposition issue with regard to office:version from ODF 1.0, ODF 1.1, and ODF 1.2.