view tests/crashgetbundler.py @ 40880:7cda0cacbbf6

util: implement pop() on lrucachedict This moves __delitem__() to pop() as the requirement is pretty much the same, and reimplement __delitem__() by using pop().
author Yuya Nishihara <yuya@tcha.org>
date Sun, 04 Nov 2018 16:57:05 +0900
parents f3807a135e43
children 2372284d9457
line wrap: on
line source

from __future__ import absolute_import

from mercurial.i18n import _
from mercurial import (
        changegroup,
        error,
        extensions
    )

def abort(orig, *args, **kwargs):
    raise error.Abort(_('this is an exercise'))

def uisetup(ui):
    extensions.wrapfunction(changegroup, 'getbundler', abort)