# HG changeset patch # User Yuya Nishihara # Date 2017-05-03 02:16:55 # Node ID b98ee1a808bd479b47d9d49bdff2bbf1473172a4 # Parent 2daba41c3b8073527bf6b62972da6f460d6b5a83 cleanup: remove useless re-raises of KeyboardInterrupt KeyboardInterrupt is no longer a subclass of Exception since Python 2.5. https://docs.python.org/2/whatsnew/2.5.html#pep-352-exceptions-as-new-style-classes diff --git a/mercurial/branchmap.py b/mercurial/branchmap.py --- a/mercurial/branchmap.py +++ b/mercurial/branchmap.py @@ -67,8 +67,6 @@ def read(repo): partial.setdefault(label, []).append(node) if state == 'c': partial._closednodes.add(node) - except KeyboardInterrupt: - raise except Exception as inst: if repo.ui.debugflag: msg = 'invalid branchheads cache' diff --git a/mercurial/extensions.py b/mercurial/extensions.py --- a/mercurial/extensions.py +++ b/mercurial/extensions.py @@ -171,8 +171,6 @@ def loadall(ui): continue try: load(ui, name, path) - except KeyboardInterrupt: - raise except Exception as inst: inst = _forbytes(inst) if path: