Browse Source

fsck: remove unnecessary raises

The called functions already raise RetryFsck.
tags/nilmdb-2.2.0
Jim Paris 6 months ago
parent
commit
7f8a2c7027
1 changed files with 2 additions and 2 deletions
  1. +2
    -2
      nilmdb/fsck/fsck.py

+ 2
- 2
nilmdb/fsck/fsck.py View File

@@ -287,7 +287,7 @@ class Fsck(object):
files = list(filter(regex.search, os.listdir(subpath)))
if not files:
self.fix_empty_subdir(subpath)
raise RetryFsck # pragma: no cover; raised by fix_empty_subdir
# Verify that their size is a multiple of the row size
for filename in files:
filepath = os.path.join(subpath, filename)
@@ -364,7 +364,7 @@ class Fsck(object):
erow = tab[epos-1] # noqa: F841 unused
except Exception as e:
self.fix_bad_interval(sid, intv, tab, str(e))
raise RetryFsck # pragma: no cover; raised by fix_bad_interval
return len(ints)

def fix_bad_interval(self, sid, intv, tab, msg):


Loading…
Cancel
Save