KeyError with non-existent repositories (hgwebdir.cgi)

Brendan Cully brendan at kublai.com
Sat Jul 14 14:52:12 CDT 2007


On Saturday, 14 July 2007 at 15:27, Maxim Khitrov wrote:
> Hello,
> 
> I'm trying to configure hgwebdir.cgi script to serve a few of my
> repositories via Lighttpd. I'm using rewrite rules to send all
> requests to the cgi script, and the whole thing works great for the
> repositories that are there.
> 
> My question is about requests for non-existent directories. If I try
> to access some random path that does not point to a valid repository,
> I get a KeyError message with a ton of output containing the call
> trace. My problem with this is that it exposes all the relevant paths
> on the server. Where hgwebdir.cgi is running from, where python is
> installed, and so on. I'm curious to know if there is some way to
> suppress this output? For example, just send a 404 error instead.

You are probably running the hgwebdir gitweb style? It was missing the
'notfound' template for a long time. It was fixed about a week ago in
d39776752a1f.



More information about the Mercurial mailing list