This is an archived snapshot of W3C's public bugzilla bug tracker, decommissioned in April 2019. Please see the home page for more details.

Bug 3636 - Constr-ws-xmlspace-2
Summary: Constr-ws-xmlspace-2
Status: CLOSED FIXED
Alias: None
Product: XML Query Test Suite
Classification: Unclassified
Component: XML Query Test Suite (show other bugs)
Version: 1.0.2
Hardware: PC Windows XP
: P2 normal
Target Milestone: ---
Assignee: Andrew Eisenberg
QA Contact: Mailing list for public feedback on specs from XSL and XML Query WGs
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2006-08-27 22:20 UTC by Michael Kay
Modified: 2006-11-30 15:21 UTC (History)
0 users

See Also:


Attachments

Description Michael Kay 2006-08-27 22:20:52 UTC
test Constr-ws-xmlspace-2 takes the form:

<elem xml:space="strip"> </elem>

In XML, the two legal values of xml:space are "preserve" and "default". It seems this is a legal query, but it generates an erroneous XML document. It's not actually a well-formedness error: the XML spec says "It is an error for other values [than 'preserve' or 'default'] to be specified; the XML processor MAY report the error or MAY recover by ignoring the attribute specification or by reporting the (erroneous) value to the application. 

As it happens the System.Xml parser on .NET does report the error, which makes it impossible to compare the result of this query with the expected results.

I shall raise an issue on the XQuery spec as to whether this query ought to be legal. Whether it's a legal query or not, however, it's not a good idea for a test in the test suite to generate a result that's an error according to the XML specification, if only because it's legitimate for the comparison with expected results to fail.
Comment 1 Andrew Eisenberg 2006-08-29 19:00:09 UTC
I'll wait for WG discussion before I take any action on this bug report.
Comment 2 Andrew Eisenberg 2006-09-20 20:36:17 UTC
The XSL and XML Query WGs discussed this issue (http://www.w3.org/Bugs/Public/show_bug.cgi?id=3704). We decided that an implementation MAY raise a dynamic error [XPDY0092] if a constructed attribute named xml:space has a value other than "preserve" or "default".

I'll modify Constr-ws-xmlspace-2, allowing error XPDY0092 in addition to its existing result.

Please close this bug report if you agree with this resolution.
Comment 3 Tim Mills 2006-11-30 15:21:26 UTC
The November 21 spec says that the error code should be XQDY0092 rather than XPDY0092.

"This change closes Bugzilla entry 3704. Sections affected: 3.7.1.3 Content, 3.7.3.2 Computed Attribute Constructors, 3.7.3.2 Computed Attribute Constructors, and new error code XQDY0092."