[issue 53] Making hgweb handle bad commands better

Matt Mackall mpm at selenic.com
Mon Nov 7 20:40:07 UTC 2005


On Sun, Nov 06, 2005 at 09:12:37PM -0800, Eric Hopper wrote:
> This is made rather difficult by the fact that hgweb has this code:
> 
>             req = hgrequest(self.rfile, self.wfile, env)
>             self.send_response(200, "Script output follows")
>             hg.run(req)
> 
> This basically sends an 'OK' response before a lot of the request
> processing happens.  This isn't really the correct behavior.  But,
> determining what _is_ the correct behavior isn't obvious.

I disagree. 200 is an HTTP protocol level response. The Mercurial
protocol runs on a layer above that. We need to report errors at that
level.

-- 
Mathematics is the supreme nostalgia of our time.



More information about the Mercurial mailing list