chrisjshull / homebridge-nest

Nest plugin for HomeBridge
699 stars 112 forks source link

Is Google Rate Limiting Me? #602

Closed TopBanana123 closed 1 year ago

TopBanana123 commented 1 year ago

I first started using this plugin a year or so ago with no problems, but around 6 months ago I noticed that it would sometimes show "Disconnected" in the HomeKit UI. And I also noticed the Nest app would not connect to the thermostat sometimes

I figured it was a Nest issue, and I put it on my list to deal with later. I'm digging into it more and I get the following error in HomeBridge

[2/2/2023, 10:14:45 PM] [Nest] Could not authenticate with Nest (code ECONNABORTED). Retrying in 15 second(s). [2/2/2023, 10:17:19 PM] [Nest] API observe: error { code: 'ETIMEDOUT' } [2/2/2023, 10:17:19 PM] [Nest] ^^^^^ this message is for information only, it does not mean there is a problem, please do not file a ticket unless you actually have a problem with the function of the plug-in [2/2/2023, 10:17:19 PM] [Nest] Retrying in 10 seconds.

But, there is something odd. While this is failing (It will connect eventually) and the app doesn't work, if I switch to cell data or any other connection, it works.

To add, it only stopped working properly when I set an automation to turn on a humidifier when the humidity got low. I wonder how often its pinging the thermostat through the API for that

Could it be that Nest is rate limiting my IP?

adriancable commented 1 year ago

No. This is a connection timeout. It's a network issue. (with your machine, ISP or the Nest service)

Rate limits give rise to a 429 error (not ECONNABORTED). The plug-in has various mechanisms to avoid hitting rate limits so you should never see this error.

TopBanana123 commented 1 year ago

Thanks!

TopBanana123 commented 1 year ago

For anyone else with the same problem, the issue is something between AT&T's ipv6 network and Nest and MyQ

I turned off ipv6 on the Homebridge VM, and now everything works fine.

DNS for both ipv6 and ipv4 is CloudFlare and Google, so it doesn't seem to be a DNS issue, must be on the ISP side

jnubz commented 1 year ago

I turned off IPv6 ages ago thanks to it not working well with my Plex server. My issue was specifically with my Eero devices, but I also have AT&T, so I suppose it could've been a dual issue.