From 13dcaae591ff39caaa5251fcb2c0254fb8b7397e Mon Sep 17 00:00:00 2001 From: Matt Turnbull Date: Fri, 28 Aug 2009 07:43:12 +0100 Subject: [PATCH] Exceptions, Eric style (lost in merge) --- pyfpdb/Exceptions.py | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/pyfpdb/Exceptions.py b/pyfpdb/Exceptions.py index 44ed2d65..fb386ac3 100644 --- a/pyfpdb/Exceptions.py +++ b/pyfpdb/Exceptions.py @@ -1,8 +1,3 @@ -class DuplicateError(Exception): - def __init__(self, value): - self.value = value - def __str__(self): - return repr(self.value) class FpdbError(Exception): def __init__(self, value): @@ -10,7 +5,7 @@ class FpdbError(Exception): def __str__(self): return repr(self.value) -class FpdbParseError(Exception): +class FpdbParseError(FpdbError): def __init__(self,value='',hid=''): self.value = value self.hid = hid @@ -20,4 +15,6 @@ class FpdbParseError(Exception): else: return repr(self.value) +class DuplicateError(FpdbError): + pass