Re: [XHR] test nitpicks: MIME type / charset requirements

I hear you, but isn't having a case-sensitive value of Content-Type *in
certain circumstances* triggering the kind of problem you're talking about
("developers to depend on
certain things they really should not depend on") ?

As I see it, the tests in question here are doing something that is "wrong"
in the general use-case from an author's POW.

By requiring the same from every *implementor*, aren't we pushing *authors *in
the trap you describe. Case in point : the author of the test is testing
Content-Type case-sensitively while it is improper (from an author POW) in
any other circumstance. The same code will fail if, say, the server sets a
Content-Type. Shouldn't we protect authors from such inconsistencies ?



On 7 May 2013 01:39, Anne van Kesteren <annevk@annevk.nl> wrote:

> On Mon, May 6, 2013 at 4:33 PM, Julian Aubourg <j@ubourg.net> wrote:
> > It seems strange the spec would require a case-sensitive value for
> > Content-Type in certain circumstances.  Are these deviations from the
> > case-insensitiveness of the header really necessary ? Are they beneficial
> > for authors ? It seems to me they promote bad practice (case-sensitive
> > testing of Content-Type).
>
> There's only two things that seem to work well over a long period of
> time given multiple implementations and developers coding toward the
> dominant implementation (this describes the web).
>
> 1. Require the same from everyone.
>
> 2. Require randomness.
>
> Anything else is likely to lead some subset of developers to depend on
> certain things they really should not depend on and will force
> everyone to match the conventions of what they depend on (if you're in
> bad luck you'll get mutual exclusive dependencies; the web has those
> too). E.g. the ordering of the members of the <canvas> element is one
> such thing (trivial bad luck example is User-Agent).
>
>
> --
> http://annevankesteren.nl/
>
>

Received on Monday, 6 May 2013 23:55:33 UTC