Patchwork [5,of,6] repoview: add a FilteredRepoLookupError

login
register
mail settings
Submitter Pierre-Yves David
Date Oct. 16, 2014, 9:30 a.m.
Message ID <56cca5ebc3c92d9affec.1413451810@marginatus.alto.octopoid.net>
Download mbox | patch
Permalink /patch/6323/
State Accepted
Headers show

Comments

Pierre-Yves David - Oct. 16, 2014, 9:30 a.m.
# HG changeset patch
# User Pierre-Yves David <pierre-yves.david@fb.com>
# Date 1413450372 25200
#      Thu Oct 16 02:06:12 2014 -0700
# Node ID 56cca5ebc3c92d9affecd349fd0b01c4dca9128e
# Parent  b1c281d9e3f520f013736d74f6f1e239d0dd94d1
repoview: add a FilteredRepoLookupError

This exception is a more precise RepoLookupError that will allow us to issue
special message when we end up accessing a filtered revision.

Patch

diff --git a/mercurial/error.py b/mercurial/error.py
--- a/mercurial/error.py
+++ b/mercurial/error.py
@@ -63,10 +63,13 @@  class RepoError(Exception):
         self.hint = kw.get('hint')
 
 class RepoLookupError(RepoError):
     pass
 
+class FilteredRepoLookupError(RepoLookupError):
+    pass
+
 class CapabilityError(RepoError):
     pass
 
 class RequirementError(RepoError):
     """Exception raised if .hg/requires has an unknown entry."""