2.0 Release Update

If I send something to notify.notify it only goes to my phone… it should go to everything but seems to be only 1 device. I don’t think it’s the iOS app doing this.

Anyone else seeing wild locations coming in to HA even when the app log says it’s “ignoring” the location due to it being not accurate enough?

Both of our phones are “wandering” outside of the large 300m geofence I’ve placed around our home and showing up on the HA map miles and miles away. App is saying it ignored the update, HA seems to still be getting it. Background Fetch or Manual, doesn’t seem to matter.

Also been seeing HA 0.100 (all versions so far) ignoring that the devices are well inside multiple geofence areas and still displaying them on the map inside the geofence. Like dead center in the things. Haha.

Just awake at 3AM and tinkering with HA here, watching my phone leave home and come back occasionally while it’s next to me on the charger. LOL. Funny.

Setup: Latest HA and iOS Beta (68), iPhone X, latest iOS 13 as of right now.

Follow up on the above. First time I have seen this. Wife’s phone is currently showing miles away in a completely different rural town.

HA is showing a geofence up around her centered on THAT location, and she’s still showing on the map in the center of it.

NOT a zone defined in the HA config at all.

Looks like Apple may be screwing with Robbie and all of us. Did their server stick that geofence around her? Would HA know about it from the integration? That’s just strange.

Her phone is in a basement that has both incredibly poor GPS and Cellular coverage, rural home. Whatever it’s reporting it probably completely bogus or is Verizon’s network taking a wild ass Assisted GPS guess by the tower it’s reaching out here. Likely it’s over in that town which is closer to population and the Interstate.

To give details without exposing house location in logs is difficult but for general perspective, we live in the northwest corner of Elbert County in Colorado. Her phone is currently showing its location as being in Bennett, Colorado. It’s that wildly off.

1 Like

Sounds like it’s nothing to s=do with ios app to me. Have you tried using a GPS app on the phone (there are free ones) to check the GPS location? HA will only have whatever the phone sees… It will also show a last updated time as well.

I have same thing here with crazy teleportations

99.3
ios 13.1.3
iphone 10
Home Assistant 2.0b

1 Like

Yeah most GPS apps seem to ignore the location provided by iOS when iOS reports the accuracy as low (unknown threshold — probably app driven). Whatever iOS apps do to get a more accurate reading from the iOS location built in (I believe Apple hides the raw GPS data and apps have to ask Location Services, but I haven’t looked into it in a long time on the coding side of things) they wait and get one within a few seconds.

Companion beta app also reports that it’s ignoring the location in the app event log, but seems to really not ignoring it and sending it to HA. That’s my best guess from the event log and the HA log.

One of the accuracy ignore statements says its greater than 8000m which is total insanity. That has to be just thrown out. But here’s my phone saying it’s at least that far away occasionally while just sitting here. Haha.

Entertaining at least. I don’t rely on it for presence at home, that’s for sure. Person for both of us is configured to also use the WiFi router integration (Netgear) so my false night time “away” count is very low and only happens if the iPhones drop off of WiFi and sleep. Which since they’re doing WiFi calling at home is nearly never. The constant traffic to Verizon’s VoIP servers and various other notifications and such, keep them both active on WiFi nearly all the time.

I haven’t had time to correlate 100% that the “ignored” updates in the App event log are exactly what HA is getting. I’ll see if I can make some time tomorrow / later today to do side by side log comparison. I dumped tonight’s event log to my Dropbox from the phone so I should be able to correlate timestamps, assuming HA doesn’t need to be in a higher than default logging level to output what it’s getting for exact locations in updates.

It’s definitely interesting. :slight_smile:

Weird, works absolutely fine for me for months now. Though I use a tado tracker as well. It literally hasn’t failed a single time and I rely heavily on this app. I even have an iPhone X which has gps issues ever since they have released it (hardware issues) though they mitigated the problem through software to my knowledge.

Anyways I don’t think the app is the culprit here. But then again if you have a bad reception indoor it could be just that your walls/isolation keeps the gps signal from coming through properly.

Yeah understand, I do RF engineering… nobody has good GPS indoors. :slight_smile: You alway have to give even a great GPS receiver time to converge indoors, and phone GPS receivers are crippled by awful antennas.

I think the real weirdness here is the app says it’s doing the right thing in event logs and ignoring the bad location, but that location is still reaching the HA server.

Funny story: Wife left early this morning. I had left my phone off the charger. It went dead around the time I woke up. Last location it sent was a wandering one, so now I’m not “home” both in the case of the GPS location AND the WiFi router. All my “everyone is away” automations fired, and I started wondering why my indoor cameras started eyeballing me and alerting on me, as well as why other things happened – hahaha!

Clearly this isn’t the best solution for us. LOL!

Glad I’m not arming the monitored alarm with it yet! Could’ve had a Sheriff visit in my skivvies! HAHAHA!

The only presence detection I am really happy with and I use in an automation is one based on a ping sensor to my Wife’s phone.
I have found a long lag at times with the GPS position in the iOS app. It is starting to look ok and I’m toying with it and the here_now travel time sensor but still not implemented.

Here’s logs of this evening sanitized…
Phone has moved around inside house but mostly sitting next to me on the desk.

HA LOGBOOK:
4:43 PM Nate Geocoded Location changed to *** HOME ***
5:12 PM Nate Geocoded Location changed to *** THREE HOUSES AWAY IN PROPERTY THAT HOUSES SIT ON FOUR ACRES ***
5:25 PM Nate Geocoded Location changed to *** HOME ***
6:10 PM Nate Geocoded Location changed to *** SAME AWAY PROPERTY AS BEFORE ***
6:25 PM Nate Geocoded Location changed to *** HOME ***
7:43 PM Nate Geocoded Location changed to *** NEIGHBOR AGAIN ***

APP EVENT LOG SAME TIMEFRAME:

4:43 looks normal, triggered by entering the geofence around “Home”

5:12 A background fetch starts right at log rotation to a new file…

2019-10-25 17:12:11.549 [Verbose] [main] [AppDelegate.swift:227] application(_:performFetchWithCompletionHandler:) > Background fetch activated at Oct 25, 2019 at 17:12:11 Mountain Daylight Time!

new file, removed logger notice about file rotation…

`2019-10-25 17:12:11.551 [Warning] [main] [WebhookSensors.swift:297] getLatestMotionActivity() > Motion permission not enabled
2019-10-25 17:12:11.572 [Verbose] [main] [HAAPI.swift:506] GetAndSendLocation(trigger:) > getAndSendLocation called via BackgroundFetch
2019-10-25 17:12:11.589 [Info] [main] [ClientEventStore.swift:23] ClientEventStore > ClientEvent {
date = 2019-10-25 23:12:11 +0000;
text = Ignoring one shot location with accuracy over threshold.Accuracy: 263.0239512427212m;
typeString = locationUpdate;
jsonData = <(null) — 0 total bytes>;
}
2019-10-25 17:12:11.591 [Verbose] [main] [WatchHelpers.swift:85] BuildWatchRenderTemplatePayload() > complications Results <0x10335d3c0> (

)
2019-10-25 17:12:11.592 [Verbose] [main] [WatchHelpers.swift:91] BuildWatchRenderTemplatePayload() > mostRecentlyReceievedContext.content nil []
2019-10-25 17:12:11.592 [Verbose] [main] [WatchHelpers.swift:127] updateComplications() > No complications have templates, not sending the request!
2019-10-25 17:12:20.026 [Verbose] [main] [OneShotLocationManager.swift:43] locationManager(_:didUpdateLocations:) > LocationManager: Got 1 locations, stopping updates!
2019-10-25 17:12:20.031 [Info] [main] [HAAPI.swift:477] SubmitLocation(updateType:location:zone:) > Location update payload: [“gps_accuracy”: 50.0, “gps”: [REDACTED, REDACTED], “speed”: 0.0, “altitude”: 1865.509952545166, “vertical_accuracy”: 48.0, “battery”: 43]
2019-10-25 17:12:20.190 [Warning] [main] [WebhookSensors.swift:297] getLatestMotionActivity() > Motion permission not enabled
2019-10-25 17:12:20.191 [Warning] [main] [WebhookSensors.swift:217] getLatestPedometerData() > Motion permission not enabled
2019-10-25 17:12:20.192 [Verbose] [main] [WatchHelpers.swift:85] BuildWatchRenderTemplatePayload() > complications Results <0x102625ac0> (

)
2019-10-25 17:12:20.193 [Verbose] [main] [WatchHelpers.swift:91] BuildWatchRenderTemplatePayload() > mostRecentlyReceievedContext.content nil []
2019-10-25 17:12:20.193 [Verbose] [main] [WatchHelpers.swift:127] updateComplications() > No complications have templates, not sending the request!
2019-10-25 17:12:20.915 [Verbose] [main] [HAAPI.swift:493] SubmitLocation(updateType:location:zone:) > Device seen via webhook!
2019-10-25 17:12:20.920 [Info] [main] [ClientEventStore.swift:23] ClientEventStore > ClientEvent {
date = 2019-10-25 23:12:20 +0000;
text = Current location delivery triggered via background fetch;
typeString = locationUpdate;
jsonData = <length = 24, bytes = 0x7b0a2020226770735f616363757261637922203a2035302c — 185 total bytes>;
}
2019-10-25 17:12:20.922 [Verbose] [main] [AppDelegate.swift:753] setupFirebase() > Logging event location_update to analytics`

I’ll just stop there… I see the phone is lying to the app. The REDACTED Lat/Long are the neighbor’s land next door well over 300m away, but the phone reported 50m accuracy. That’s BS, but not the App’s fault.

Not sure how the App can deal with it, other than ask for multiple locations in a row and see if the phone tends to get two out of three right, or what… but if the phone says 50m accuracy and drops the coordinates over 300m from where it actually is, there’s nothing the App can EASILY do about it.

It looks like the App also did the right thing and got an inaccurate location first that even the phone said was inaccurate, and then asked again. Phone said 50m so it sent it to HA.

Would be interesting to track if this happens on only one carrier – mine is Verizon and since the phone is using assisted GPS with tower locations factored in, and they are VERY far apart out here… I wonder if the phones give inaccurate junk locations.

I skimmed the other events and they’re all similar. Phone is lying about accuracy… sigh.

I grepped out all the GPS lines from the app event logs to see how much the reported GPS accuracy changed…

Got a kick out of this one… it got ignored… see gps_accuracy

og_2019-10-25_174545.txt:2019-10-25 17:35:25.473 [Info] [main] [HAAPI.swift:477] SubmitLocation(updateType:location:zone:) > Location update payload: [“gps_accuracy”: 5005.0, “vertical_accuracy”: 10.0, “altitude”: 1890.879150390625, “gps”: [REDACTED, REDACTED], “battery”: 38]

IRONY: It maps right on top of the house!!! LOL!!!

ohhh interesting… As I watch the logs I see multiple accuracies of “5005.0”

I remember a previous post by @robbiet480 saying that another accuracy number that came up repetitively for someone else was really an indication that the GPS was assisted perhaps by the tower/cell site.

Also interestingly those coordinates aren’t very far off, and definitely inside the Home (altered by me) 300m geofence… while others with better accuracies are a long long way away.

Apple or Verizon or whoever, appears to be using that “5005.0” as an indicator of something. It is repetitive in my App log. Neat, and weird.

Okay, coffee time… :slight_smile:

Could you try the version 1.5 of the app and see if you have the same problem? That may discard a faulty gps on your iPhone or a bug on the app.

I think @robbiet480 should see that. Maybe he will say something on discord, because he seems to be active there.

I’m sure he will see it here in due time. Not going to bug him with it. It’s clearly some weirdness either in iOS or the network I’m on.

Cheers all. That was a fun little debugging session. I got sidetracked into node-red fun after that. Ha. So many toys, so little free time.

One of the two phones we’re running build 68 on has been getting these every few days. Often times following the location services dialog.

iPhone 7, iOS 13.1.3, HA 0.100.3

After reloading the App, there are scrollbars in some views.
After tapping another and going back they are gone.

Is this related the the new frontend with 0.101.0bx?

No clue, i’m using the beta since 0.101.x.
Before i used 1.5

Just I saw similar in beta 101. In b0 it was totally screwed up and I think after b1 and a new frontend it was fixed up. Anyway, I think the issue is HA, not the iOS beta app.