##// END OF EJS Templates
error: add CensoredNodeError, will be thrown when content deliberately erased...
Mike Edgar -
r22595:24447868 default
parent child Browse files
Show More
@@ -193,6 +193,8 b' def _runcatch(req):'
193 ui.warn(_(" empty string\n"))
193 ui.warn(_(" empty string\n"))
194 else:
194 else:
195 ui.warn("\n%r\n" % util.ellipsis(inst.args[1]))
195 ui.warn("\n%r\n" % util.ellipsis(inst.args[1]))
196 except error.CensoredNodeError, inst:
197 ui.warn(_("abort: file censored %s!\n") % inst)
196 except error.RevlogError, inst:
198 except error.RevlogError, inst:
197 ui.warn(_("abort: %s!\n") % inst)
199 ui.warn(_("abort: %s!\n") % inst)
198 except error.SignalInterrupt:
200 except error.SignalInterrupt:
@@ -117,3 +117,9 b' class ReadOnlyPartError(RuntimeError):'
117 """error raised when code tries to alter a part being generated"""
117 """error raised when code tries to alter a part being generated"""
118 pass
118 pass
119
119
120 class CensoredNodeError(RevlogError):
121 """error raised when content verification fails on a censored node"""
122
123 def __init__(self, filename, node):
124 from node import short
125 RevlogError.__init__(self, '%s:%s' % (filename, short(node)))
General Comments 0
You need to be logged in to leave comments. Login now