Thanks. In no particular order: * I guess HEAD has been neglected since conditional-GET got popular (and the latter is very useful, just not in my particular case here). * My client falls back to GET if the HEAD fails, just like Pawel's example appears to have done. * A change to Paste (or for that matter to Routes) should probably wait for guidance in the WSGI specification on where the original method should be saved.
Taking all these together, I'm left with either doing nothing (because of the fallback) or providing a small (non-standard, because there is no standard) middleware component for those servers that care about the wasted/failed requests. That's ok - like I said earlier, I'm not sure how serious this is from an implementation perspective but it would be nice if the spec could cover this issue at some point. Regards, Mike P.S. If you're interested in what triggered this conversation, I pushed a working PathTo and a slightly better documented DescribedRoutes up to bitbucket last night - see http://bitbucket.org/asplake/path_to/wiki/Home and http://bitbucket.org/asplake/described_routes/wiki/Home. I'll make a separate announcement when I'm happier with usage instructions, docstrings and the like. On Feb 4, 11:09 pm, Paweł Stradomski <[email protected]> wrote: > W liście Mike Orr z dnia czwartek 04 lutego 2010: > > > I thought that the purpose of HEAD was to tell whether a resource had > > changed, and that it had effectively been made obsolete by > > If-Modified-Since and Etag. I suppose you could use HEAD to see if > > the resource exists or you have permission to view it, but I don't > > know of anybody that does that. In any case, these uses do not depend > > on Content-Length. The only use of prechecking Content-Length is, um, > > to see how large the response is? > > Some bots do: > "HEAD /posts/3 HTTP/1.1" 405 0 "-" "WordPress.com > mShots;http://support.wordpress.com/contact/" > "GET /posts/3 HTTP/1.1" 200 7160 "-" "WordPress.com > mShots;http://support.wordpress.com/contact/" > "HEAD / HTTP/1.1" 405 0 "http://www.netcraft.com/survey/" "Mozilla/4.0 > (compatible; Netcraft Web Server Survey)" > > This is from a site that does not translate HEAD into GET but does check if > request method is acceptable (and forgets to account for HEAD) > > -- > Paweł Stradomski -- You received this message because you are subscribed to the Google Groups "pylons-discuss" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/pylons-discuss?hl=en.
