--- a/mercurial/hgweb/hgwebdir_mod.py Sat Mar 10 11:03:45 2018 -0800
+++ b/mercurial/hgweb/hgwebdir_mod.py Sat Mar 10 10:56:10 2018 -0800
@@ -287,6 +287,11 @@
real = repos.get(virtualrepo)
if real:
wsgireq.env['REPO_NAME'] = virtualrepo
+ # We have to re-parse because of updated environment
+ # variable.
+ # TODO this is kind of hacky and we should have a better
+ # way of doing this than with REPO_NAME side-effects.
+ wsgireq.req = requestmod.parserequestfromenv(wsgireq.env)
try:
# ensure caller gets private copy of ui
repo = hg.repository(self.ui.copy(), real)