core: Google Nest integration failed to set up
The problem
The devices and entities provided by the google nest integration became unavailable on upgrade to 2021.9.2
What is version of Home Assistant Core has the issue?
core-2021.9.2
What was the last working version of Home Assistant Core?
core-2021.8.8
What type of installation are you running?
Home Assistant Core
Integration causing the issue
Google Nest
Link to integration documentation on our website
https://www.home-assistant.io/integrations/nest/
Example YAML snippet
No response
Anything in the logs that might be useful for us?
Logger: homeassistant.config_entries
Source: components/nest/__init__.py:166
First occurred: 8:51:45 PM (1 occurrences)
Last logged: 8:51:45 PM
Error setting up entry Nest for nest
Traceback (most recent call last):
File "/srv/homeassistant/lib/python3.9/site-packages/homeassistant/config_entries.py", line 304, in async_setup
result = await component.async_setup_entry(hass, self) # type: ignore
File "/srv/homeassistant/lib/python3.9/site-packages/homeassistant/components/nest/__init__.py", line 166, in async_setup_entry
await subscriber.start_async()
File "/srv/homeassistant/lib/python3.9/site-packages/google_nest_sdm/google_nest_subscriber.py", line 172, in start_async
await self._subscriber_factory.async_new_subscriber(
File "/srv/homeassistant/lib/python3.9/site-packages/google_nest_sdm/google_nest_subscriber.py", line 80, in async_new_subscriber
return await loop.run_in_executor(
File "/usr/lib/python3.9/concurrent/futures/thread.py", line 52, in run
result = self.fn(*self.args, **self.kwargs)
File "/srv/homeassistant/lib/python3.9/site-packages/google_nest_sdm/google_nest_subscriber.py", line 101, in _new_subscriber
subscriber = pubsub_v1.SubscriberClient(credentials=creds)
File "/srv/homeassistant/lib/python3.9/site-packages/google/cloud/pubsub_v1/subscriber/client.py", line 102, in __init__
channel = grpc_helpers.create_channel(
File "/srv/homeassistant/lib/python3.9/site-packages/google/api_core/grpc_helpers.py", line 306, in create_channel
composite_credentials = _create_composite_credentials(
File "/srv/homeassistant/lib/python3.9/site-packages/google/api_core/grpc_helpers.py", line 236, in _create_composite_credentials
credentials = google.auth.credentials.with_scopes_if_required(
TypeError: with_scopes_if_required() got an unexpected keyword argument 'default_scopes'
Additional information
No response
About this issue
- Original URL
- State: closed
- Created 3 years ago
- Comments: 31 (9 by maintainers)
I’m so happy I found this thread tonight, I’d been scouring the internet trying to figure out a fix. Thank you all!!
After I installed Simple Wyze Vac, I kept getting the
'google.protobuf.descriptor' has no attribute '_internal_create_key'error that @vidvisionify mentioned. At first I thought it was the Core or OS upgrade I just installed, so I rolled back to the last Core backup but I was still getting the same error.The Google Home integration also got killed by the protobuf version downgrade. I removed both the Nest and Google Assistant integrations, but when I tried to re-add them I got the “Could not load config flow” message on both. I had to comment out my Nest entry in the
configuration.yamlin order to reboot HA Core.I also recently got the Google Assistant integration set up (the one to add HA entities to Google Home, not run Google Assistant on HA), and today when I was looking through the logs I noticed that it was also throwing the
'google.protobuf.descriptor' has no attribute '_internal_create_key'error, although it wasn’t completely breaking the integration (HA devices would still show up in Google Home, but the HomeGraph API component wouldn’t load IIRC).@alanjames1987 you rock, thanks for adding that protobuf dependency. I’ve now got HA-Wyze installed to fix the protobuf issue, and Simple Wyze Vac installed since I already have scripts and automations set up with the syntax for that integration. @romedtino could you also add
"protobuf==3.13.0"to your manifest requirements? It seems to have completely fixed the issue for me (re: https://github.com/romedtino/simple-wyze-vac/issues/5)Thank you all for your contributions! Being able to integrate all of my Wyze devices in HA has been a game changer.
@codypet I unfortunately don’t know how Home Assistant caches, separates, and overall manages the different environments that different integrations consume. I will look into that and see if there could be a conflict between integrations.
However, I believe Home Assistant installs dependencies when you first setup the integration, not when you install or uninstall the integration.
However again, HACS could manage lower level dependencies completely differently.
@codypet I’ve made an update to force protobuf 3.13.0 to be the version that is installed. Try installing the update and see if that fixes your problem. You might need to uninstall the integration completely because, like I said above, I don’t know how HA and HACS manage lower level dependencies.
I’ve heard that
ha core rebuildcan help if the custom component got your integrations stuck in Home Assistant OS.