tests/crashgetbundler.py
author Pierre-Yves David <pierre-yves.david@octobus.net>
Mon, 29 May 2023 04:24:29 +0200
changeset 50632 786443bd3bc1
parent 48875 6000f5b25c9b
permissions -rw-r--r--
store: cache the file_size when we get it from disk The point of caching `files` is to ensure consistency and avoiding redoing expensive work. So we cache the file_size once retrieved.

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)