rmceoin / cominghome

Coming Home sets away/home with Nest Thermostats on Android
Apache License 2.0
2 stars 1 forks source link

Application is setting nest to Away arbitrarily #10

Open vanstinator opened 8 years ago

vanstinator commented 8 years ago

Since the latest update my wife and I have both noticed Coming Home is setting our thermostat to "Away" all the time. We also can count on having the notification with the timer on it very often as well. Application history doesn't show a geofence event being triggered unless we actually go somewhere, so that part is working fine. I notice at least one negative review on the appstore from November 24 that is probably tied to this as well.

As a side note in my history last night I had some JSON objects that looked like errors from a Google API that reached quota.

rmceoin commented 8 years ago

Argh! Yes, other folks are reporting the away issue. This is a bit frustrating for me since I didn't modify the geofence code. That's really in Google's hands through the Play Services. But it does seem when I updated to a newer library of Play Services it may have activated a newer version of the Play Service location services.

Anyway, I've been busy adding the ability to also track WiFi SSID. I'm hoping that would help cut down on false positive away's.

Somebody else shared a screenshot of the JSON error as well. I can only guess it's indicative of the extra backend calls.

Backend error: 503 Service Unavailable
{
 "errors": [
  {
   "domain": "global",
   "reason": "backendError",
   "message": "com.google.apphosting.api.ApiProxy$OverQuotaException: The API call datastore_v3.Put() required more quqota than is available."
  }
  ],
  "code": 503, "message": "com.google.apphosting.api.ApiProxy$OverQuotaException: The API call datastore_v3.Put() required more quqota than is available."
} w:M```
vanstinator commented 8 years ago

But you log when a geofence event is triggered and I'm not seeing extra geofence logs... Hmm...

That's the same log I was seeing On Nov 25, 2015 11:40 AM, "Randy McEoin" notifications@github.com wrote:

Argh! Yes, other folks are reporting the away issue. This is a bit frustrating for me since I didn't modify the geofence code. That's really in Google's hands through the Play Services. But it does seem when I updated to a newer library of Play Services it may have activated a newer version of the Play Service location services.

Anyway, I've been busy adding the ability to also track WiFi SSID. I'm hoping that would help cut down on false positive away's.

Somebody else shared a screenshot of the JSON error as well. I can only guess it's indicative of the extra backend calls.

Backend error: 503 Service Unavailable { "errors": [ { "domain": "global", "reason": "backendError", "message": "com.google.apphosting.api.ApiProxy$OverQuotaException: The API call datastore_v3.Put() required more quqota than is available." } ], "code": 503, "message": "com.google.apphosting.api.ApiProxy$OverQuotaException: The API call datastore_v3.Put() required more quqota than is available." } w:M```

— Reply to this email directly or view it on GitHub https://github.com/rmceoin/cominghome/issues/10#issuecomment-159666330.

rmceoin commented 8 years ago

That's a good point. Can you share a screenshot of your History that shows what you're talking about?

rmceoin commented 8 years ago

I've published a new beta version 1.1.7 to the store. You can opt in at:

https://play.google.com/apps/testing/net.mceoin.cominghome

Feedback would be greatly appreciated. d13087c1b7b66b45243adda48a6894f4319ac8ea

vanstinator commented 8 years ago

Note I left for work at 7:44 A.M. The backend updated just fine, and then it tried 3 more times. It does this at home as well. What's interesting is it realizes my wife is home so it claims it's not switching the nest to away, but last night it was definitely constantly going into away mode. My smart lights are linked to my nest too, and at least once or twice an hour all my lights would shut off.

screenshot_20151125-121336

vanstinator commented 8 years ago

Look through logs last night again I am seeing a large amount of geofence logs. It's possible something broke with the google library as you postulated originally.

I've also added myself to the beta group and will download the update as soon as it's available.

rmceoin commented 8 years ago

Okay, now I understand what you mean about the "Backend updated: Nest not updated: Others at home" without a corresponding "Geofence left home". Makes me wonder if those are repeated attempts to contact the backend as a result of the original geofence trigger.

With the beta 1.1.7 I also bumped to the very latest 8.3 Play Services. It mentions some new location API changes. Nothing that indicates bug fixing, but I haven't run into a full declaration of changes that they actually do, so you never know.

vanstinator commented 8 years ago

My wife has been working from home all day and mentioned she's had the "Going Away" notification coming up all morning, which she then cancels. We were both experiencing that all night last night. When I was at work this morning after triggering my geofence going away I didn't see the notification again, so something causes it to trigger while we're home outside of a geofence update.

EDIT: I'm now running your 1.1.7 beta, and I'm home. I've reset my home so it's now aware of my wifi. I'll let you know if I run into any issues. While this should keep the errant away status from triggering it'd still be nice to get to the bottom of what was triggering it in the first place.