From c2c45e061edf01531307c4f28207eef9dc362f51 Mon Sep 17 00:00:00 2001 From: doctorpangloss <@hiddenswitch.com> Date: Thu, 17 Jul 2025 13:06:55 -0700 Subject: [PATCH] fix noisy logging messages --- comfy/cmd/main_pre.py | 1 + comfy/nodes/vanilla_node_importing.py | 6 +++--- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/comfy/cmd/main_pre.py b/comfy/cmd/main_pre.py index f8b63534e..669d0ff9a 100644 --- a/comfy/cmd/main_pre.py +++ b/comfy/cmd/main_pre.py @@ -45,6 +45,7 @@ log_msg_to_filter = "NOTE: Redirects are currently not supported in Windows or M logging.getLogger("torch.distributed.elastic.multiprocessing.redirects").addFilter( lambda record: log_msg_to_filter not in record.getMessage() ) +logging.getLogger("alembic.runtime.migration").setLevel(logging.WARNING) from ..cli_args import args diff --git a/comfy/nodes/vanilla_node_importing.py b/comfy/nodes/vanilla_node_importing.py index 41eaddf94..1feccf2d8 100644 --- a/comfy/nodes/vanilla_node_importing.py +++ b/comfy/nodes/vanilla_node_importing.py @@ -101,11 +101,11 @@ def _vanilla_load_importing_execute_prestartup_script(node_paths: Iterable[str]) logger.error(f"ComfyUI-Manager security_check failed but was caught gracefully: {e}", exc_info=e) security_check.security_check = patched_security_check - logger.info("Patched ComfyUI-Manager's security_check to fail gracefully.") + logger.debug("Patched ComfyUI-Manager's security_check to fail gracefully.") # Patch logging logging.Logger.addHandler = no_op_add_handler - logger.info("Patched logging.Logger.addHandler to prevent ComfyUI-Manager from adding a logging handler.") + logger.debug("Patched logging.Logger.addHandler to prevent ComfyUI-Manager from adding a logging handler.") time_before = time.perf_counter() success = execute_script(script_path) @@ -303,7 +303,7 @@ def mitigated_import_of_vanilla_custom_nodes() -> ExportedNodes: if not getattr(threading.Thread.start, '__is_patched_by_us', False): threading.Thread.start = patched_start setattr(threading.Thread.start, '__is_patched_by_us', True) - logger.info("Patched `threading.Thread.start` to propagate contextvars.") + logger.debug("Patched `threading.Thread.start` to propagate contextvars.") _vanilla_load_importing_execute_prestartup_script(node_paths) vanilla_custom_nodes = _vanilla_load_custom_nodes_2(node_paths) return vanilla_custom_nodes