]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
pybind/cephfs: move LibCephFSStateError closer to base class
authorRishabh Dave <ridave@redhat.com>
Fri, 13 Dec 2019 06:51:03 +0000 (12:21 +0530)
committerRishabh Dave <ridave@redhat.com>
Thu, 9 Jan 2020 11:03:32 +0000 (16:33 +0530)
At first look it appears that class OSError is the only class derived
from class Error which makes class Error look redundant. Therefore, it's
better to move class LibCephFSStateError from the bunch of exception
classes derived from OSError to closer to class Error.

Signed-off-by: Rishabh Dave <ridave@redhat.com>
src/pybind/cephfs/cephfs.pyx

index 975abd26c581a58cfbf7ec3776232fda661f2359..c2027707c7c74dd6703662ff478ead3c02d4ea1d 100644 (file)
@@ -187,6 +187,10 @@ class Error(Exception):
         return 1
 
 
+class LibCephFSStateError(Error):
+    pass
+
+
 class OSError(Error):
     def __init__(self, errno, strerror):
         super(OSError, self).__init__(errno, strerror)
@@ -232,10 +236,6 @@ class OperationNotSupported(OSError):
     pass
 
 
-class LibCephFSStateError(Error):
-    pass
-
-
 class WouldBlock(OSError):
     pass