Closed mynameisdaniel32 closed 4 years ago
logger documentation logger source (message by IssueLinks)
This is likely due to the fixes in #35633 that solved the lost log messages on startup and is unrelated to the earlier startup.
The logger configuration isn't activated until the logger integration is loaded so this seems like its working as designed but we shouldn't have info messages if verbose startup is off
Actually with #35749 we can probably safely remove the respect_handler_level
statement now
diff --git a/homeassistant/util/logging.py b/homeassistant/util/logging.py
index 943e701a14..ed710f573f 100644
--- a/homeassistant/util/logging.py
+++ b/homeassistant/util/logging.py
@@ -77,9 +77,7 @@ def async_activate_log_queue_handler(hass: HomeAssistant) -> None:
logging.root.removeHandler(handler)
migrated_handlers.append(handler)
- listener = logging.handlers.QueueListener(
- simple_queue, *migrated_handlers, respect_handler_level=False
- )
+ listener = logging.handlers.QueueListener(simple_queue, *migrated_handlers)
listener.start()
This should fix it but it might cause a regression were we loose logger messages again. But that might not be an issue with the other fixes so more testing is needed
Appears that the log message dropping problem doesn't regress and #35749 doesn't regress with respect_handler_level
taken out.
I want to do some more testing to be sure before taking it out
Tested your change on my system but logs are still filled with INFO events at startup.
Tested your change on my system but logs are still filled with INFO events at startup.
Do you have verbose mode turned on?
Looks like there is one more place we need to change
if you mean my logger config, it's the following
logger:
default: warning
logs:
homeassistant.loader: error
homeassistant.components.tplink.switch: error
homeassistant.components.media_player: error
@luca-angemi Can you try the code in the linked PR #36444
@bdraco tested!
All the INFO are gone. Only these types are remaining
2020-06-04 16:11:49 WARNING (MainThread) [homeassistant.loader] You are using a custom integration for hpprinter which has not been tested by Home Assistant. This component might cause stability problems, be sure to disable it if you experience issues with Home Assistant.
Is this because the loader logger component, loads later?
Yes, that is expected.
The problem
Maybe an inevitable side effect of having everything start up together and faster (which is great!) but now getting logs flooded with INFO events on each startup until logger is started up, despite having my default set to WARN. Example below.
Environment
Problem-relevant
configuration.yaml
Traceback/Error logs
Additional information