2022.8: You can fix it!

Restart your host (RPi4). This seems to occasionally occur after a HA Core update. Restarting Home Assistant doesn’t seem to resolve it, but restarting the host does. Hopefully this will be resolved in 2022.9, as I believe there are some further improvements to the Bluetooth integration planned. See the YouTube Release Party video for 2022.8, where some future plans are discussed.

1 Like

Already did this. a few restarts. Still the same error.
After that, I completely shut down my RPI. Restarted… Same error.

Update: after the restart I got the same error. It’s been about 20 minutes ago now, and I just had a look at it again, and … Error Gone !
weird… Maybe it was retrying in the background for a while… Strange. So, for the moment… it seems to work.
Thanks for your reply!

HAOS 9.x has newer firmware blobs that might help with this (only in dev). 2022.9.x (in beta tomorrow) has a method to periodically check adapters that get into a bad state and recover them.

3 Likes

@Jc2k it’s the update. When I check the BLEM sensor it has updated within a matter of minutes but when I check the Bluetooth the last update is usually hours before. You mentioned the update frequency, is there a way for me to change that.?

@Sand the BLE sensor doesn’t appear to be taking the mean value because it’s always identically to what the status is in the Android app and as far as I know the app shows the exact current value. And if I understand what you mean by smoothing, the updates to the BLEM sensor are very frequent and in constant intervals so there’s more of an exact reading. Looking at the graph I can see changes in brightness due to clouds temporarily blocking the sunlight as opposed to the Bluetooth which is so sporadic. If anything the Bluetooth seems to be taking the mean and smoothing because the updates will show anywhere from minutes apart and then go to being hours apart.

Unfortunately it’s an environment issue and really hard to reproduce. I have those sensors working locally with the official HA container. They work really well.

We know that comparing to BLEM is not helpful in diagnosing what is going on. I’m always unsure about how technical to describe it, but BLEM uses a low level receive only “sniffing” approach. HA goes through the full Linux Bluetooth stack - it has to so we can support controlling devices and polling devices. There are more moving parts though. This means we aren’t just facing new HA bugs but BlueZ, dbus and kernel bugs.

In addition to that BLEM has an auto recover mechanism to restart crashed dongles. HA gets one in the September release, but in the meantime if BLEM recovers the dongle from a bad start it could be Bluez or HA isn’t recovered at the same time.

Unfortunately again this is very specific to your own personal setup. The guy working on this has 10’s of devices running HA and even more kinds of Bluetooth dongles, and more sensors and locks and bulbs than I can count and while he has seen device failures the only way he can recreate them in testing is to wait days or do chaos testing (rapid restarts of system components) to try and stress the drivers. One theory is that it is worse in BT dense areas and some buffer in bluez is getting filled.

The next HA release can recover more system failure and the next HAOS release has newer firmware and drivers. Hopefully that will help.

My problems went away when I got a different dongle.

BLEM should be doing smoothing btw, and the new Bluetooth HA stuff does not. It’s one of the differences on our backlog.

2 Likes

As I wrote a few messages before, I have a Homekit Bluetooth LED Strip which is a RGB+CWWW one. But in HA I can only control it in RGB. The CWWW part is not recognised.
Is this a problem that is fixed in the meantime?

What is CWWW? Does it work with the official Apple app?

HA has something called RGBWW, which is an (r, g, b, cw, ww) tuple (not normalized for brightness). Is that what you mean?

EDIT: So the most recent spec I have for HAP (the HomeKit protocol), i can’t see support for that color mode. So it’s probably not something I can help with. If you raise a GitHub issue and attach the full diagnostic information for your light i can check for undocumented characteristics (i.e. APIs that aren’t in the spec) that might be able to help.

Hello, thank you for this new release.
I installed python 3.10; how can I be sure homeassistant is using it instead of the 3.9?
Thanks in advance

Thank you for your answer!

Yes, correct. The strip has extra LED for warm and cold white.
In Homekit it is possible to control RGB and cold/warm white. I also have the ZigBee version of this strip connected to Home Assistant via deCONZ and there it is possible to control RGB and cold/warm white.

OK, I will do. Where can I find the diagnostic information?

I found the System/System Health page, and it says:
Python Version 3.9.0

If I run python3 --version the answer is Python 3.10.6.

Now: how do I make HA run on Python 3.10?
Thanks!

In the integrations page, find the homekit_controller area. Click on your device and then click on the “…” menu as below. Do “Download diagnostics”.

Screenshot 2022-08-31 at 13.16.02

1 Like

@eric10k93 or @jagermyster - either of you brave enough to try the latest update to ZwaveJS (0.1.68). Does look like they have a change relates to S0 security. I’m a bit gun shy so will wait until I have a bit more time to do the update.

I have tried all sorts of changes honestly… I downgraded to .64, but my devices seem to be botched after that last update. Updating to .68 didn’t resolve anything. I think I will have to reset each of the messed up devices honestly. I really wish I knew what went wrong. I’ve not seen anything like this in all the years of using zwave.

Okay, so its the weekend, and I have some time, so I updated to 0.1.68…

Same issue as 0.66, in that all my Fibaro devices will give status updates, but can’t be controlled. Looks like whatever the S0 security change made in 68 didn’t deal with the main issue. (Aeon devices still functioned under 66 and 68).

That being said, rolling back both the .68 to last made partial backup, and .66 to last FULL backup - both of which rolled back to .65 fixed the problems.

As such, not sure if your problem @eric10k93 is the same issue as ours.

What install type do you have?

I had similar problems after upgrading from .65 z-wave JS so I have migrated over to ‘ Z-wave JS to MQTT’ add-on and all is good again. Plus as a reward for all the additional work I now have really cool z-wave network map

Yeah, my specific issue seems to be that my devices are either totally unresponsive (offline), they appear to be online but are unresponsive, and they are online but are extremely slow to respond.

About 1/3 of my devices randomly did this after the last zwave JS update… But rolling back to previous versions unfortunately doesn’t fix anything. It’s like something in the zwave update or the HA update made my zwave configuration go corrupt to the point it’s unrecoverable. It really doesn’t make sense to me that using a backup wouldn’t fix things… I’m just not sure what to look for as I am not sure where all the files that zwave uses are located… I’m not sure I would know what to look for even if I knew where all the files were.

At this point, I am considering nuking the whole thing and starting fresh… Would give me a good excuse to update my zwave USB stick to a newer model anyway… It’s entirely possible something to do with the USB stick has gone bad… Just seems strange it would coincide with an update to HA.

EDIT: In case anyone stumbles on this later… it all started working again for me… after we had a power outage today. I had tried cutting power to individual circuits and devices that were not working, but that never fixed anything. I had also tried rebooting the server itself various times, with no luck. Oddly, we had a full power outage today and all the devices came back up and are working perfectly. I can’t explain it, but if this happens again, I will definitely be cutting the whole house power. It’s almost like there was some extraneous signal getting bumped around the network and the only way to get rid of it was to kill everything at once… I don’t know if that can actually happen in a Zwave network or not, but the full power outage fixed all my devices.

I have Home Assistant Core

Quite complex to update python in core, sorry I am not sure then.

You need to create a new venv using your Python 3.10. Within the venv, python3 will alias to whatever version was used to create it. Then reinstall hass inside that new venv.

1 Like