Google Home Integration Failing after authentication

Did an update to my C7 hub that included an update for additional GH features (added zwave lock support I think). After the update and enabling said devices in the Hubitat GH app, resyncing seema to have broke. I removed Hubitat from GH and tried adding it back but everything I do results in a "Could not reach Hubitat. Please try again." I've removed GH from hubitat and Hubitat from Google home. I've rebooted both the hub and phone. I've uninstalled/reinstall both the Hubitat and GH apps but they refuse to finish integration.

Google does communicate because when adding hubitat it has me login with my hubitat credentials, it'll have me select which hub (there's only one) and then it'll have me select which devices I want to add but shortly after I select the "Authorize" button it craps itself. Every time it does this hubitat automatically installs the GH app (tells me it's actually authenticating) but after it authenticates and tries to get devices info it fails.



What’s likely happening here is that with the latest Google Home integration updates, you have a device (driver) that’s missing required functionality for the capabilities it advertises.

Example, a fan (capability FanControl) missing a supportedFanSpeeds attribute will cause that “text cannot be null” error.

Once the null error pops the GH integration device update fails.

I had this happen with the example I provided above and had to remove the device from Google Home until I fixed the driver to populate supportedFanSpeeds.

The problem is all my devices have been linked/integrated with GH in the past except locks. Since the lock is what started this issue I tried linking without it and generally no dice. I took @jtp10181 suggestion and tried linking with only one device and then going back and adding more and it somewhat worked. The first device added and allowed for the two platforms to link. Then I tried 3 additional devices of the exact same type but when asking Google to sync it said something went wrong with hubitat. Then about 10 minutes later the 3 additional devices show up on my GH app.

I thought maybe there was a change to where devices are pushed automatically now because in the past I've always had to resync in order for any new device that's been exposed to GH to be pushed to it. I tried with more devices but it failed to sync and no additional devices showed up in GH. The fact that it's failing to sync in general has me concerned.

The device add functionality in the GH integration hasn't changed, you add the device in Hubitat, the re-open the google home app on your mobile device, I've not ever had to force a device sync.
If there's a specific device that's not working as expected, then go into the GH integration options and enable debug logging, then re-add the offending device and post the live logs.

1 Like

In the 5 years I've been using either a C5 or C7 a forced sync has been the only way to get any devices I've added in Hubitat to be pushed to GH. I've never seen the devices show up in the GH app just by enabling the device in Hubitat. Syncing/communication reliability between Hubitat and GH was so bad that I set a nightly routine a couple years ago in GH to resync with third party platforms and it significantly improved reliability, so I left it. I’m not saying this is the norm only that this is my experience.

All the devices I'm trying to add have already been added previously without issue. The only thing that changed was the firmware on my C7 and adding my z-wave lock (of which has been added before but removed since it wasn't officially supported in a usable way) when I saw the lock feature support added. So really the only thing that's changed is just the firmware. Anyway, that's when GH started to fail to sync whether automatically or via forced. I went back and removed the lock and rebooted my Hubitat but that didn't fix it. I then disconnected Hubitat/GH from each other, reinstalled both apps, power cycled the Hubitat and tried integrating everything back as it was before, but GH couldn't connect. I've done this integration with GH probably 100 or more times in the past (experimenting with fans and locks) without much issue so this is the first time I've seen this happen.

I then took Jeff's suggestion of adding one device first and then adding more and that somewhat worked. It did allow GH to authenticate when adding the first device but forced syncing failed when adding a couple more devices though they did ultimately appear in GH but none since.

The point is all my devices have been connected to GH previously with little issues and now they refuse to. Forced syncing GH has generally always worked and when it didn’t a power cycle usually fixed it. Now neither work - I shouldn't be getting the "something went wrong when syncing Hubitat" notification from Google when I sync. The only thing that’s changed in all this, is the firmware.

I'll try and get additional log screenshots especially as I have most everything set to logging already but so far they're not any different from what I originally posted.

Well if you think it’s the Hubitat platform version then I would revert and see if the issue goes away.

Is your internet unreliable?, that’s the only reason I can think of that would require you to go through those gymnastics to get synchronized

My plan is to revert back to 184 when I get home tonight if I have time. If that fixes the issue I'm curious as to whether it has something to do with the other thread where people are experiencing cloud disconnects. I just read through some of it and I had the same notification of cloud disconnect after making the update which as mentioned when everything with GH started going wrong. Anyway that's just me speculating but I do plan to try and revert back and see what happens.

Generally my internet is pretty solid; gigabit fiber to the home with a wifi7 system - obviously the C7 is hardwired though. I haven't checked my routers logs but I haven't noticed anything that would indicate intermittent internet.

I have recently experienced a similar problem. All of my connected devices between Google Home and Hubitat went offline like Google was unable to communicate with the Hubitat cloud. I was having one heck of a time getting anything to happen. I tried just reauthorizing, Then adding a device and then removing it i finally noticed similar errors. Finally, I ended up removing the Google integration completely and tried to add it back. I ended up with a new error were it would fail constantly on the Google side during the Auth process. I finally found a thread on here talking about some other folks with similar problems. Apparently some drivers are causing this problem. I started to add a few devices at a time and it started working.

The specific example I found was referencing Fan drivers from a community integration that was causing the problem. I am gradually working my way through it now that i have started adding devices back, but I think whatever process is suppose to catch unsupported devices is missing something. The example seemed to be related to fan devices. Try removing any fan devices and see if that helps it work better and not generate errors.

@mike.maxwell
I just went through and added several devices one at a time got a good portion of my setup back. When I added a Fan devices I got these errors. App 2249 is Google Home

The fan devices in question is a older Hampton Bay Zigbee Fan controller using the built in Driver. It still works and doesn't generate errors itself. This is a new occurrence.

This caused me to consider testing my fan Driver for a Govee Tower fan I have. It generated this error.

I hope that helps. I am going to just remove those devices since they don't seem to be functional through Google Home

1 Like

They should work, can you send me a screen shot of the current states shown in the driver details?


That is the Zigbee Hampton Bay controller with built in Driver.

Here is the error with debug logging turned on. I see the debug and warn messages a few times through the log and then eventually eventually get the error message

the driver is missing the supportedFanSpeeds attribute, I'll add that into the next build, it will update once you click configure in the next platform version

2 Likes

have you enabled the Enable component devices preference?

I saw that there was another update to 196 from 193 so I tried that update hoping it may have fixed the issue but it didn't. I then reverted back to 180 and guess what?! Everything popped into GH and all syncing issues are gone. The problem lies with the latest firmware.

If you could get some error logs like @mavrrick58 did then Mike can figure out the issue.

Sounds like exactly the issue but I removed everything except my Zen77 dimmers and it still failed.

I'll try and get some logs tonight. my plan is to recreate what happened but in a methodical or organized manner now that I know going back to 180 works. I want to make sure that the issue stems from checking for compatible devices. The majority of my device is are the zen77 dimmers which utilize the advanced drivers that Jeff has been maintaining. The drivers work fine when it comes to GH integration for version 180 But when I was trying to do this from just a handful of devices for 193 I was focusing on the zen77s. Even then The single device I use to establish the connection was a zen77 so I'm not for sure which is why I want to it experiment a little bit.

The weird thing is the three devices that I was able to get to integrate were zen77s however, Google still wouldn't do the forced sync function and what makes it weird is that despite syncing/reconnecting failing Google was getting state updates for those devices.

Just like @mavrrick58 I updated to the new platform version and methodically went through adding all my devices to GH. Unlike last time the common devices added fine. Knowing the fans were where some people were getting hung up I left those for last. Needless to say everything added fine... Until I got to the fans and ran into the same issue. It appears the fans were the underlying issue. The fan switches I have are Leviton ZW4SF and I use a community driver that can be found here developed by Ernie Miller. They worked fine with 180 but no longer work with 193/196. The log info whenever I add a fan to GH.

I feel like there is something weird happening here. I have several Govee Drivers that i have configured to use the "Fan Control " capability. The second device i commented above had a different self inflicted issue i fixed and it is working fine now, I also have Air Purifier drivers that use similar code for the fan control part of the driver. Basically the only adjustment was @field map value for the different speeds available by device and the Air Purifier doesn't work. Something is screwy with Google Home and Fan Control devices.

None of my drivers have a attribute for supportedFanSpeeds. When i create the driver using some examples from other threads it doesn't fix the issue in the failing drivers

I think @gatewoodgreen has those fan controllers, Google Home, and also is using some sort of community driver which may be working (or he fixed it himself)? He might be able to get you pointed in the right direction. Otherwise fixing the driver you are using should not be too bad of a task for a driver developer.

The "FanControl" capability automatically defines supportedFanSpeeds and it is up the driver to populate it. I believe with the updated GH integration it is requiring that to be populated in order for fans to be compatible. It would probably cause far less trouble if it was designed to fall back to the prior behavior if that attribute is null/blank...

I have a custom virtual fan driver which populates it. You can toss this in the configure command:

sendEvent(name: "supportedFanSpeeds", value: supportedSpeed[numSpeeds as Integer])

(where numSpeeds is 3,4 or 5 and pulls from a map in the code)

Here is my Map for 3,4 or 5 speeds

@Field static Map<Integer, List> supportedSpeed = 
[
	3: ["low","medium","high","on","off"],
	4: ["low","medium-low","medium-high","high","on","off"],
	5: ["low","medium-low","medium","medium-high","high","on","off"]
]

Could also just plop the list right into the event like this:

sendEvent(name: "supportedFanSpeeds", value: ["low","medium","high","on","off"])
2 Likes