write: add the possibility to pass keyword argument from batchget to vfs
We are going to pass atomictemp keyword argument from merge.baychget to
vfs.__call__. Update all the frames to accept **kwargs and pass it to the next
function.
Differential Revision: https://phab.mercurial-scm.org/D1881
# A dummy extension that installs an hgweb command that throws an Exception.
from __future__ import absolute_import
from mercurial.hgweb import (
webcommands,
)
def raiseerror(web, req, tmpl):
'''Dummy web command that raises an uncaught Exception.'''
# Simulate an error after partial response.
if 'partialresponse' in req.form:
req.respond(200, 'text/plain')
req.write('partial content\n')
raise AttributeError('I am an uncaught error!')
def extsetup(ui):
setattr(webcommands, 'raiseerror', raiseerror)
webcommands.__all__.append('raiseerror')