Skip to content

Commit

Permalink
🧑‍💻 Add debug logger of module node registry
Browse files Browse the repository at this point in the history
  • Loading branch information
Asthestarsfalll committed Dec 3, 2024
1 parent 5288b64 commit 06663f1
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions excore/config/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,9 @@ def _is_special(k: str) -> tuple[str, SpecialFlag]:
"""
match = FLAG_PATTERN.match(k)
if match:
logger.ex(f"Find match `{match}`.")
return match.group(2), match.group(1) # type: ignore
logger.ex("No Match.")
return k, ""


Expand Down Expand Up @@ -329,3 +331,4 @@ def register_special_flag(flag: str, target_module: NodeType, force: bool = Fals
global FLAG_PATTERN
FLAG_PATTERN = re.compile(rf"^([{''.join(SPECIAL_FLAGS)}])(.*)$")
_dispatch_module_node[flag] = target_module # type: ignore
logger.ex(f"Register new module node `{target_module}` with special flag `{flag}.`")

0 comments on commit 06663f1

Please sign in to comment.