I have about three to four integrations that are ‘Failed to set up’ and HA just tells me to ‘Check the logs’. I now have to dig through System, Logs and scroll through to find why my Integration is not loaded. Wouldn’t be simpler if the logs were listed right in the integrations page similar to how devices contains the Logbook?
This would be awesome, but also i believe something easy to implement. My HA full log is so big that it crashes the browser/text editors when im trying to search in it
How long has it been since you restarted HA? Do a restart and you’ll get a fresh log file. Your previous log file will be renamed as log1 and eventually be overwritten on your next restart
This is really bad for troubleshooting because often errors dont actually happen on the initialisation, so youre losing error messages by doing that
At the very least it should link to the logs page. I find it quite annoying.
Unless you restart twice in a row, then you can simply navigate to the config folder and create a local copy of log1 any time you want.
The problem with this is that all integrations write to the Home Assistant Core log.
There is currently no way to filter these logs by Integration, which is what would be required for this WTH to be implemented. Addons, on the other hand, get their own dedicated logs in the dropdown, which make things much simpler to troubleshoot.
I agree with the idea to have a link to dedicated logs in the integration page (when/if a log filter feature is introduced).
I do not agree with the original proposal to shove those logs to the side of the page where only 25% of the page size is available. The current logs barely fit in the existing full size Logs page and text gets truncated. Imagine the number of lines each log entry would have to take if the available space gets reduced by a factor of 4.
But that brings me to back to the problem of dealing with often 30MB+ log files in a text editor. Whats not always easy or straightforward - feel sorry for the users of windows notepad.
And i guess this is what this WTH is about, it would be easy to not make user dig in one huge .log file at all but displaying integration messages on the integration page.
I’m not sure what log format is being used by the system log, but I gotta believe data is being pulled from some table.
In terms of the logs dialog box in the integration page, it doesn’t have to be placed to the right like the Devices logbook. That was just an example. It can go anywhere on that page or even hidden if there are no errors/warnings.
you can access the log from previous boot on system / log in the top right 3 dot menu
Looking into this further, it seems that the Integration name is part of the system log, albeit it doesn’t seem to clearly reflect the ‘actual’ name in some cases. E.g. SmartThings seems to error out as part of ‘Config Entries’?
2024-12-28 08:08:17.263 ERROR (MainThread) [kasa.smart.smartdevice] Error querying 192.168.0.81 for modules 'Cloud, DeviceModule, LightPreset, LightTransition, Time' after first update: ("Device connection error: 192.168.0.81: Cannot connect to host 192.168.0.81:80 ssl:False [Connect call failed ('192.168.0.81', 80)]", ClientConnectorError(ConnectionKey(host='192.168.0.81', port=80, is_ssl=False, ssl=False, proxy=None, proxy_auth=None, proxy_headers_hash=None), OSError(113, "Connect call failed ('192.168.0.81', 80)")))
2024-12-28 08:08:18.370 ERROR (MainThread) [homeassistant.config_entries] Error setting up entry My home for smartthings
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/config_entries.py", line 640, in __async_setup_with_context
result = await component.async_setup_entry(hass, self)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/components/smartthings/__init__.py", line 129, in async_setup_entry
token = await api.generate_tokens(
^^^^^^^^^^^^^^^^^^^^^^^^^^
...<3 lines>...
To @dinth’s point, I think it would make sense to have this information on the Integration’s page at a glance, rather than having the user go to the system log and have to search for the integration name.