operating-system: Bluetooth blocking issue 'Event loop stopped before Future completed' when OS>5.11

Hardware Environment

  • Raspberry Pi 4b

Home Assistant OS release:

  • Updated from version 5.11
  • Additional information (if accessible):

System Health

version core-2021.2.3
installation_type Home Assistant OS
dev false
hassio true
docker true
virtualenv false
python_version 3.8.7
os_name Linux
os_version 5.4.83-v8
arch aarch64
timezone Europe/Paris
Home Assistant Community Store
GitHub API ok
Github API Calls Remaining 4982
Installed Version 1.11.3
Stage running
Available Repositories 751
Installed Repositories 18
Home Assistant Cloud
logged_in false
can_reach_cert_server ok
can_reach_cloud_auth ok
can_reach_cloud ok
Hass.io
host_os Home Assistant OS 5.12
update_channel stable
supervisor_version supervisor-2021.03.4
docker_version 19.03.13
disk_total 219.4 GB
disk_used 11.5 GB
healthy true
supported true
board rpi4-64
supervisor_api ok
version_api ok
installed_addons File editor (5.2.0), Terminal & SSH (9.0.2), Samba share (9.3.1), Mosquitto broker (5.1.1), Node-RED (8.1.3), InfluxDB (4.0.3), phpMyAdmin (0.2.0), Grafana (6.1.3), Zigbee2mqtt (1.18.1-1), MariaDB (2.2.2), Z-Wave JS (0.1.10), Z-Wave JS to MQTT (0.6.1), Glances (0.11.1)
Lovelace
dashboards 2
resources 11
views 11
mode storage

Description of problem: Opening an issue here as it was suggested to me on this issue: https://github.com/custom-components/ble_monitor/issues/295 After upgrade to 5.12, bluetooth works for some time then suddenly crash after a few hours and requires a host reboot to work again for a few hours before crashing again. Rollback to 5.11 works (managed to have a whole week without issues after rollback) And before 5.12 upgrade, everything had been working for months When crashing, I have following error message in the logs: **ERROR (Thread-3) [custom_components.ble_monitor] HCIdump thread: Runtime error while stop scan request on hci0: Event loop stopped before Future completed.**

Additional details can be found in the issue mentioned above, but don’t hesitate if I can provide any more details ! Thanks for the help

About this issue

  • Original URL
  • State: closed
  • Created 3 years ago
  • Comments: 19 (3 by maintainers)

Most upvoted comments

Please test with 6.2 again.

Tested with every new version of OS from 5.11 to 6.5

Only 5.11 does not show this issue

For the users of BLE monitor we have now implemented a workaround, that powers on Bluetooth and unblocks Bluetooth. (bluetoothctl power on and rfkill unblock bluetooth) in case of this error. You will have to turn this on in the options of BLE monitor, as it is disabled by default.

It seems that for some reason, the power state of the Bluetooth adapter is turned off, so the first command is tuning it back on. This workaround works if the error occurs occasionally, but one of the users has reported that in his case, it is powered off so often that this workaround is still unusable.

This “fix” is of course a workaround, it is not solving the actual problem why Bluetooth is powered off in the first place. I have no clue why this happens.

@agners When installing 5.11, is the firmware update reverted as well, or does it keep the firmware version?