Patchwork [2,of,4] error: derive RevlogError from HintException instead of Exception

login
register
mail settings
Submitter Jordi Gutiérrez Hermoso
Date May 21, 2015, 8:30 p.m.
Message ID <88b99c48761cc7b982b8.1432240220@Iris>
Download mbox | patch
Permalink /patch/9217/
State Accepted
Commit 4311e78a4609ec0df4b3b0a75ab6d130e5df258c
Headers show

Comments

Jordi Gutiérrez Hermoso - May 21, 2015, 8:30 p.m.
# HG changeset patch
# User Jordi Gutiérrez Hermoso <jordigh@octave.org>
# Date 1432239634 14400
#      Thu May 21 16:20:34 2015 -0400
# Node ID 88b99c48761cc7b982b84294aa679b63f5edf967
# Parent  1afb582cf7f85118a1c48c69aaa54625db5afab0
error: derive RevlogError from HintException instead of Exception

This will allow us to now pass hints into this exception.
Matt Mackall - May 22, 2015, 5:15 p.m.
On Thu, 2015-05-21 at 16:30 -0400, Jordi Gutiérrez Hermoso wrote:
> # HG changeset patch
> # User Jordi Gutiérrez Hermoso <jordigh@octave.org>
> # Date 1432239634 14400
> #      Thu May 21 16:20:34 2015 -0400
> # Node ID 88b99c48761cc7b982b84294aa679b63f5edf967
> # Parent  1afb582cf7f85118a1c48c69aaa54625db5afab0
> error: derive RevlogError from HintException instead of Exception

These first two are queued for default, thanks.

Patch

diff --git a/mercurial/error.py b/mercurial/error.py
--- a/mercurial/error.py
+++ b/mercurial/error.py
@@ -18,7 +18,7 @@  class HintException(Exception):
         Exception.__init__(self, *args)
         self.hint = kw.get('hint')
 
-class RevlogError(Exception):
+class RevlogError(HintException):
     pass
 
 class FilteredIndexError(IndexError):