NEST - Issues with lost internet connectivity
See original GitHub issueThe problem
There are several issues within this report. First the background / timeline
The Nest thermostat is the downstairs thermostat referenced in the logs.
Event 1 - 2022-04-19 03:01:17 Home Power lost - switched over to backup generator. Home assistant / routers on UPS. So this went smoothly.
Event 2 - 2022-04-19 06:58:09 - Internet went out because the cable companies battery backup on the poles had expired.
Event 3 - 2022-04-19 23:38:07 - Power was restored to the cable company - partial internet was restored including VPN between houses.
Event 4 - To restored full internet access required a remote router reboot.
Event 5 - 2022-04-20 14:49:41 - Utility Power Restored
Observations:
- The climate entity in Home Assistant never went unavailable and continued to show the temperature / state at Event 2. After Event 4, the climate entity did not start updating and required a home assistant restart.
- As expected, after Event 2, setpoint command were throwing errors.
- After Event 3, the setpoint command were not throwing errors ( 2022-04-20 04:54:59) and were not succeeding. It may be these were going through to Google, but since the NEST was offline they were not fully getting processed.
- The Nest App on my phone did show the Nest device was offline.
- After Event 4, the Nest API reported that the device was offline (which was correct), but never recovered.
Issues:
- When communication to the cloud is lost the Climate Entity should go unavailable. Showing stales data gives the impression stuff is working. We may want timeout / retries here to prevent false positives with short internet glitches.
- Integration did not recover when internet access was restored.
- Setpoints did not throw errors when they did not succeed 2022-04-20 04:54:59
Considerations:
- Integration re-load. There is no way to force a reload of the integration from the configuration panel. This could be a useful capability to allow reset of the integration without having to restart Home Assistant.
- Health Sensors. The NEST App shows what devices are online / off line. Could be useful to create binary_sensors for each device and report the status.
- Attributes in the climate entity to indicate the last time data was received. This way an alert could be generated if no data is received in some timeframe.
What version of Home Assistant Core has the issue?
2022.3.6
What was the last working version of Home Assistant Core?
No response
What type of installation are you running?
Home Assistant Container
Integration causing the issue
NEST
Link to integration documentation on our website
https://www.home-assistant.io/integrations/nest/
Diagnostics information
No response
Example YAML snippet
No response
Anything in the logs that might be useful for us?
Included above
Additional information
No response
Issue Analytics
- State:
- Created a year ago
- Comments:34 (31 by maintainers)

Top Related StackOverflow Question
I have the code and tests written. Hardest part was getting the tests to run, eventually used the devcontainer which worked perfectly.
I now need to do integration testing to verify it works when the thermostat is offline and goes back online, etc. I’m not able to do that until week of 26th. Once I do that I’ll generate a pull request. The fundamental change is to climate_sdm.py adding this piece of code:
I restored power to the NEST today, within 1 minute, I started getting new data into Home Assistant. So the integration does recover from the situation. Hence, it looks like its just the detection on the device going offline that is needed.
I downloaded a new diagnostic file about 6 hours after restoration.
It still shows this, but also all the temperatures are incorrect. Is this a capture from integration startup?
nest_diagnostics_power_restore.txt
The other test I will run is what happens when I prevent the integration from having Internet, as we’d also may want it to become unavailable if the cloud is unreachable.