- From: Francois Daoust <fd@w3.org>
- Date: Thu, 20 May 2010 15:33:39 +0200
- To: Jo Rabin <jo@linguafranca.org>
- CC: Mobile Web Best Practices Working Group WG <public-bpwg@w3.org>
Following the group's resolution on Tuesday, I added the erratum to the errata document (linked from the top of the mobileOK Basic Tests 1.0 spec): http://www.w3.org/2008/12/mobileok-errata.html#ed-1 Francois. On 05/06/2010 03:56 PM, Jo Rabin wrote: > I'm grateful to Francois for stepping me through the ins and outs of > this rule (off line), and apologise to him for being opaque in my > understanding - but I now see what he means and agree with his proposed > erratum. > > I'd go further and say that the clause relating to HTTP_RESPONSE-11 > could be better clarified as: > > [[ If the HTTP status represents failure (4xx), other than *in any of > the following cases: i)* the HTTP status is 404, *ii) the HTTP status > represents* a request for authentication (e.g. 401) or *iii) the HTTP > status is* 406 *for object elements (but not any other elements)* when > carrying out the 3.15.1 Object Element Processing Rule, FAIL ]] > > Jo > > On 03/05/2010 14:49, Francois Daoust wrote: >> Hi BPWG, >> >> This is proposal to clarify the application of the HTTP_RESPONSE-11 >> failure message on images in an erratum of the mobileOK Basic Tests 1.0 >> recommendation. >> >> >> Context >> ----- >> A bit less than two years ago, on our way to finalizing mobileOK, we >> spent some time playing (sigh!) with a section in the spec entitled >> "Object Element Processing Rule": >> http://www.w3.org/TR/mobileOK-basic10-tests/#ObjectElementProcessingRule >> >> For objects that define a type "attribute" set to a content-type not >> supported by the DDC, it is actually quite normal for a server to reply >> with a 406 HTTP status code if the browser still tries to retrieve the >> resource. Mobile browsers do not have to retrieve such objects in >> theory, but the above-mentioned algorithm on object element processing >> kind of ignores the "type" attribute for good reasons that are not the >> topic of this email. >> >> As a consequence, not to trigger an HTTP_RESPONSE-11 on objects >> retrieved by the Checker for testing purpose, one of the last changes we >> made to the spec was to add an exception to the HTTP_RESPONSE-11 message >> that says that 406 status codes received when carrying out the object >> element processing rule should be ignored: >> http://www.w3.org/TR/mobileOK-basic10-tests/#http_response-11 >> (I plead guilty for that change, but the change in itself is not the >> problem anyway) >> >> >> Problem >> ----- >> The problem is that, in the absence of object elements, with the >> following code, and supposing that the image is only available as a PNG >> image and that the server returns a 406 status code when the mobileOK >> Checker tries to retrieve the image (because of the Accept HTTP field >> set by the mobileOK Checker): >> <img src="bad.png" alt="The great BPWG group" /> >> >> ... should HTTP_RESPONSE-11 be triggered? >> >> I would expect it to be the case, because the server cannot serve the >> image in the appropriate format and fails to remove the img tag (as >> opposed to object elements, it is not possible to indicate the type of >> an image using a type attribute), thus requiring a useless HTTP exchange. >> >> Problem is the spec can be interpreted either way, IMO, because the 406 >> exception covers the whole object element processing rule which starts >> with: >> [[ >> For each img element that has no object element ancestor (other than the >> context node) in this context: >> Treat this image as an Included Resource (and carry out appropriate >> tests). >> ]] >> In short, the 406 exception seems to apply to img elements as well or >> not, depending on whether you treat images as regular included resources >> before or after the retrieval. >> >> >> Proposal >> ----- >> I propose to clarify, in an erratum, that the HTTP_RESPONSE-11 >> description should rather read (added text between "*"): >> [[ If the HTTP status represents failure (4xx), other than 404, a >> request for authentication (e.g. 401) or a 406 *for object elements* >> when carrying out the 3.15.1 Object Element Processing Rule, FAIL ]] >> >> >> What do you think? >> >> Francois. >> >
Received on Thursday, 20 May 2010 13:34:17 UTC