core: Shell commands return code -11 when stream component enabled
Home Assistant release with the issue: 0.91.3
Last working Home Assistant release (if known): 0.91.3
Operating environment (Hass.io/Docker/Windows/etc.): Docker
Component/platform: shell_command
Description of problem: When I enable stream component than all shell commands stop working and return code -11
Problem-relevant configuration.yaml
entries and (fill out even if it seems unimportant):
N/A
Traceback (if applicable):
019-04-11 16:22:57 ERROR (MainThread) [homeassistant.components.shell_command] Error running command: bash /config/monitor/restart_monitor.sh {{ ha_token }}
, return code: -11
NoneType: None
Additional information: If I disable stream than everything works fine
About this issue
- Original URL
- State: closed
- Created 5 years ago
- Reactions: 5
- Comments: 50 (24 by maintainers)
Everything seems to be working great on 0.98.0! I think this could probably be closed
A lot of my commands can be run via the command line components instead, I have found, and then doesn’t cause Hass to freeze when stream is enabled. This might be a good workaround for some of you others as well. I have tried the command line switch and the command line cover with success with stream enabled.
You can follow this issue over at uvloop repo: https://github.com/MagicStack/uvloop/issues/118
Ive just checked on the discord group and devs are aware hunterjm and balloob said the following “it’s a bug in uvloop and people have been looking at it”
@nicx I’m guessing they need time, and I’m also guessing that’s something we can’t really help with 😉
If you diff /usr/local/lib/python3.7 between 20191127 and 20191128 all of a sudden uvloop 0.14.0 is there, and it was not before. I see this code which is dynamically loading uvloop if it is installed, which would explain why the issue all of a sudden shows up:
https://github.com/home-assistant/home-assistant/blob/67c56c860da42c531e93fa420a558023c22e8dce/homeassistant/__main__.py#L38
@nicx I don’t pass stuff to my commands, but that is why I said it might be a workaround for some of you. 😃