Skip to content

Commit

Permalink
Tweaks imported from recent ingest-api PR
Browse files Browse the repository at this point in the history
  • Loading branch information
jswelling committed Feb 11, 2025
1 parent a7ae34a commit 482ab43
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions src/soft_assay_rules/rule_chain.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
import sys
import logging
import yaml
import json
Expand All @@ -7,7 +6,6 @@
from hubmap_commons.schema_tools import check_json_matches_schema

logger: logging.Logger = logging.getLogger(__name__)
logger.setLevel(logging.DEBUG)

SCHEMA_FILE = 'rule_chain_schema.json'
SCHEMA_BASE_URI = 'http://schemata.hubmapconsortium.org/'
Expand Down Expand Up @@ -119,8 +117,8 @@ def apply(self, rec, ctx = None):
except EngineError as excp:
logger.error(f"ENGINE_ERROR {type(excp)} {excp}")
raise RuleLogicException(excp) from excp
if 'DEBUG' in ctx:
logger.debug("DONE")
if ctx.get("DEBUG"):
logger.debug("done")
raise NoMatchException(f"No rule matched record {rec}")


Expand Down

0 comments on commit 482ab43

Please sign in to comment.