Skip to content

Commit 179ec4c

Browse files
committed
trimming a couple of debug messages
1 parent dbeeef3 commit 179ec4c

File tree

2 files changed

+2
-10
lines changed

2 files changed

+2
-10
lines changed

custom_components/pyscript/global_ctx.py

Lines changed: 1 addition & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -126,18 +126,11 @@ def find_first_file(filepaths):
126126
for ctx_name, _, _ in filepaths:
127127
mod_ctx = self.manager.get(ctx_name)
128128
if mod_ctx and mod_ctx.module:
129-
_LOGGER.debug(
130-
"module_import: returning existing module %s, ctx = %s, mod = %s",
131-
module_name,
132-
ctx_name,
133-
mod_ctx.module,
134-
)
135129
return [mod_ctx.module, None]
136130

137131
#
138132
# not loaded already, so try to find and import it
139133
#
140-
_LOGGER.debug("module_import: for module %s, searching %s", module_name, filepaths)
141134
file_info = await Function.hass.async_add_executor_job(find_first_file, filepaths)
142135
if not file_info:
143136
return [None, None]
@@ -151,15 +144,14 @@ def find_first_file(filepaths):
151144
global_ctx.set_auto_start(True)
152145
error_ctx = await self.manager.load_file(filepath, global_ctx)
153146
if error_ctx:
154-
_LOGGER.debug(
147+
_LOGGER.error(
155148
"module_import: failed to load module %s, ctx = %s, path = %s",
156149
module_name,
157150
ctx_name,
158151
filepath,
159152
)
160153
return [None, error_ctx]
161154
global_ctx.module = mod
162-
_LOGGER.debug("module_import: imported %s, ctx = %s, mod = %s", module_name, ctx_name, mod)
163155
return [mod, None]
164156

165157

custom_components/pyscript/trigger.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -527,7 +527,7 @@ def start(self):
527527
"""Start this trigger task."""
528528
if not self.task and self.setup_ok:
529529
self.task = Function.create_task(self.trigger_watch())
530-
_LOGGER.debug("trigger %s is active %s", self.name, self.task)
530+
_LOGGER.debug("trigger %s is active", self.name)
531531

532532
async def trigger_watch(self):
533533
"""Task that runs for each trigger, waiting for the next trigger and calling the function."""

0 commit comments

Comments
 (0)