Skip to content

Commit

Permalink
fix: do not override error state
Browse files Browse the repository at this point in the history
  • Loading branch information
uniqueg committed Sep 5, 2023
1 parent 88848e4 commit 54b54a3
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions htsinfer/htsinfer.py
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,8 @@ def evaluate(self):
try:
self.get_library_type()
except MetadataWarning as exc:
self.state = RunStates.WARNING
if self.state is RunStates.OKAY:
self.state = RunStates.WARNING
LOGGER.warning(f"{type(exc).__name__}: {str(exc)}")
LOGGER.info(
"Library type determined: "
Expand All @@ -111,7 +112,8 @@ def evaluate(self):
try:
self.get_read_orientation()
except MetadataWarning as exc:
self.state = RunStates.WARNING
if self.state is RunStates.OKAY:
self.state = RunStates.WARNING
LOGGER.warning(f"{type(exc).__name__}: {str(exc)}")
LOGGER.info(
"Read orientation determined: "
Expand All @@ -123,7 +125,8 @@ def evaluate(self):
try:
self.get_read_layout()
except MetadataWarning as exc:
self.state = RunStates.WARNING
if self.state is RunStates.OKAY:
self.state = RunStates.WARNING
LOGGER.warning(f"{type(exc).__name__}: {str(exc)}")
LOGGER.info(
"Read layout determined: "
Expand Down

0 comments on commit 54b54a3

Please sign in to comment.