Got the same error. Now my shell_command no longer works, it used to. Worst, doing shell_command make HA unaccessible until I restart it via docker. Running HA on Docker on Armbian.
@skynet01; In my case, the upgrade to Home Assistant 0.102.3.
@Wes93; Not solved per se, but my work-around has been to take out all shell_command entries out of my config.yaml, I am instead using command_line switches. A pain in the ass in the case of automations, but it didn’t freeze today. I do still get the error notices about UVLoop though.
…Now to deal with the weather being constantly sunny at night…
Can you elaborate on what you mean about not being able to use parameters with command line?
I’ve been having trouble for a long time with memory leaks and timeout issues with my command line and ping sensors so had to rewrite then using other components - I have stream enabled, I wonder if this has been the problem all along?
Does anyone know if shell_command will no longer work in the future as well or it’s just a temporary bug? Don’t want to rewrite my configs if all i have to do is wait
I don’t use shell_command and still I get this error in the log after each restart. Anyone here from the dev team that can help to tell from where this error origins and how int can be resolved?
yup. same thing happens to me. I’m using hassio command to restart only hassio not a full reboot because that would be a pain hassio homeassistant restart
This just started happening to me today and it keeps crashing the UI, I can restart from command line but HA never hung as many times as today and if I’m not at home it’s just dead. I have a few onvif cameras which never caused issues before.
I’m running 0.102.3 on a pi4 using HASSIO
Logs are pretty much saying this many times over:
2019-12-09 11:47:17 WARNING (MainThread) [homeassistant.components.stream] You are using UVLoop with stream and shell_command. This is known to cause issues. Please uninstall uvloop.
2019-12-09 12:29:19 ERROR (stream_worker) [homeassistant.components.stream.worker] Error demuxing stream: No dts in packet
Just started noticing the uvloop errors too in my home-assistant.log (running 0.102.3 in Docker on a nuc):
Error doing job: Exception in callback <function async_track_state_change.<locals>.state_change_listener at 0x7f5890071d40>
Traceback (most recent call last):
File "uvloop/cbhandles.pyx", line 70, in uvloop.loop.Handle._run
File "/usr/src/homeassistant/homeassistant/helpers/event.py", line 104, in state_change_listener
event.data.get("new_state"),
File "/usr/src/homeassistant/homeassistant/core.py", line 371, in async_run_job
target(*args)
File "/usr/src/homeassistant/homeassistant/components/template/binary_sensor.py", line 182, in template_bsensor_state_listener
self.async_check_state()
File "/usr/src/homeassistant/homeassistant/components/template/binary_sensor.py", line 305, in async_check_state
state = self._async_render()
File "/usr/src/homeassistant/homeassistant/components/template/binary_sensor.py", line 244, in _async_render
state = self._template.async_render().lower() == "true"
File "/usr/src/homeassistant/homeassistant/helpers/template.py", line 220, in async_render
return compiled.render(kwargs).strip()
File "/usr/local/lib/python3.7/site-packages/jinja2/asyncsupport.py", line 76, in render
return original_render(self, *args, **kwargs)
File "/usr/local/lib/python3.7/site-packages/jinja2/environment.py", line 1008, in render
return self.environment.handle_exception(exc_info, True)
File "/usr/local/lib/python3.7/site-packages/jinja2/environment.py", line 780, in handle_exception
reraise(exc_type, exc_value, tb)
File "/usr/local/lib/python3.7/site-packages/jinja2/_compat.py", line 37, in reraise
raise value.with_traceback(tb)
File "<template>", line 8, in top-level template code
File "/usr/local/lib/python3.7/site-packages/jinja2/sandbox.py", line 440, in call
return __context.call(__obj, *args, **kwargs)
File "/usr/src/homeassistant/homeassistant/helpers/template.py", line 980, in wrapper
return func(hass, *args[1:], **kwargs)
TypeError: is_state() missing 1 required positional argument: 'state'