I have a strange crash from yesterday evening: a delay in a script below causes whole script to crash and stop. In settings -->automations and scripts → if i trace script execution this error is entered:
Stopped because of unknown reason at 17. september 2025 ob 12:56:30 (runtime: 0.26 seconds)
This script worked for years, nothing has been changed long. If i delete delay script executes perfectly, while no matter where i insert delay it stops there.
Any clues? Only thing i remember doing is update browser mod…
I tried that and got same result, which points out that browser mod is not the culprit.
I didn’t find any entries in my HA log, other than misterious “script already running”, which is very strange. But if it was running then it was “locked”, since it was stuck at certain point - i know that because i inserted “notify.,send_message” after each action and wrote comments into a file to see where it stops. It always stopped just before delay command. But, just to be sure now i changed script mode from single to restart.
And to be even more baffled, thing mysteriously started to work now, so i can’t explore any further until it dies again.
Before i published this post i restarted HA a few times, i even restarted HAOS and even whole proxmox server. From then to now i didn’t do anything except updated button card. There were some error entries in log about button card before recent update:
2025-09-17 13:09:06.752 ERROR (MainThread) [frontend.js.modern.202509035] Uncaught error from Edge 140.0.0.0 on Windows 10
TypeError: this._$AH.handleEvent is not a function
Not really, since you say that then things started mysteriously running.
The kind of behavior you’re describing suggests a problem–it could be with a custom integration or it could be with some other aspect of the system–that might be manifesting at different times in different ways due to race conditions (or for that same reason sometimes not manifesting at all).
One thing people sometimes suggest is to disable integrations one at a time to see if stability improves. Sometimes that’s not really an option, though, and another way to go about this is what Petro suggested, except you need to make sure you are increasing the verbosity of logging done in your integrations and by HA.
Yeah, i agree, first thing to do in such cases is to disable addons one-by-one. I’ll have to do that if i don’t find the culprit.
I found some options to enable debug logging for hacs, i’ll try that if/when thing breaks again, perhaps it will give me some more data to work with.
Indeed… so, i guess only option is to increase log level and wait.
I always forget in which direction to go… currently i have logger set to “warn”. If i’m correct setting it to “debug” will give me more entries (and also increase HA’s workload, i guess), correct? Which level is recommended in normal conditions anyway?
To the extent you are controlling the logging level for multiple components, you probably don’t want to set everything to debug all at once–it might be a fire hose.