[RELEASE] Life360 with States - Track all attributes with app and driver. Also supports RM4 and Dashboards!

Noticed today that Life360 with states hadn't updated in quite a while. I hit "Refresh" and it updated just fine. Any idea what's going on there? Could there be built-in functionality to do a forced refresh if the status hasn't updated after X minutes?

@JustinL - the code is not responsible for the automatic refresh beyond submitting a cron job to the Hubitat core for a recurring 60 second interval. Hubitat OS then executes the refresh function in the code (same as the push button) every 60 seconds. In addition entry and exit events push a real-time refresh as well. I have very rarely encountered it going a-wall and when it did, it was due to other environmental causes.

Putting another scheduled job to check on the existing scheduled job or presence status would not yield any improvements and will put unnecessary load on the HE box. At least IMO.

If you haven’t seen updates it is likely because of a connectivity issue that caused the code to get stuck somewhere even when connectivity returned or something else on the box that messes with the HE cron scheduler. Unfortunately without debug logs it would be near impossible to understand the cause.

I will also say that in the past couple of days, Life360 was lagging status updates by a few minutes even with their own app. This happens occasionally with their server clusters whether it is the non-real time ones that feeds the API or the real-time cluster that refreshes on demand and is responsible for push notifications.

As an example when looking at the Life360 native app this afternoon for the whereabouts of my daughter, it had her as 6 minutes away as she was actually pulling her car to a parking spot right beside me.

Both my wife and I's life360 tracker devices stopped tracking location at 4:34 AM this morning. The life360 app on our phones shows the life360 ios app tracked us correctly. But the HE life360 with states app got "stuck" this morning at 4:34 AM. It updates just fine if I hit refresh manually. This is not the first time it has happened. Please advise the best way to troubleshoot this sort of connection/update issue.

@JustinL - this is not usual behavior. Have not encountered it before but I am running a custom Dev version based on the prior to current version as I've been traveling and haven't examined the latest release to integrate some updates Ive made into @bptworld's main branch just yet. I recall that the latest release updated the login sequence and believe it is probably benign but I haven't looked just yet.

Here are a few thoughts:

  1. When things get "stuck" or stalled on any of my systems, it is usually due to a disruption in connectivity. 4:34am is an odd hour and Ive experienced laps in internet connectivity due to many reasons. The most common one is an auto download of blacklist updates by my firewall or firmware updates (and reboots) by my switches, wireless controller and access point. Even my ISP's modem has caused disruptions in the middle of the night as they push firmware updates without notice.

  2. Suggest you switch the life360 apps and presence devices to debug mode and see what's going on or share on this forum via pastebin.

  3. Another suggestion is to set a time machine rule to periodically execute custom command "refreshCirclePush" on one of your life 360 presence devices - your or your wife's. Doesn't matter whom as it would reestablish a new session for all circle members. Try and schedule it to hourly perhaps in order not to call the life360 servers on this API too often. This may recover your (presumed) internet connectivity issues.

  4. Did you uninstall the Hubitat supplies Life360 app altogether? If not, please so as it clashes with the Life360 with states version.

  5. Lastly - are you on the paid version of life360 or the free one? Inasinas you may encounter some new API access limitations by Life360 on the frequency and number of calls to the free version vs the paid one. Given that I am on the paid one, I would not be able to experience the same. There are many users or @bptworld's port of this code and I would think that if it was a code issue, many others on this forum would have expressed the same issue but the thread seems to be quiet on these.

Good luck and please let us know?

1 Like

Free version, for now at least. I can't seem to find anywhere on the internet that details if there is an API call limit and what that limit is. But, I think you're right - if the issue was an API call limit, that would be happening to more than just me...

I've turned on debug logging on both the app and the device level and will report back any suspicious logs...I would rather uncover the underlying issue that address it via scheduled refreshes.

@bptworld & @9369292f1992a7d0e654 -

This notification was displayed when I logged into life360.com, any idea if this will impact this app? Thanks!

No idea! :man_shrugging:

Will know for sure on May 10th! :eyes:

1 Like

Here is the official announcement. While we don’t know what will happen it seems that it affects the web site only. My uneducated guess is that very few, if any, are using the web front-end given the app use case is 100% mobile so they may decided it is not worth the trouble to continue and maintain the web site but who knows, they may be preparing for an M&A activity given their latest strategic partnerships and will be integrated into someone else’s systems. All of that is pure speculation on my part.

Life360 had a pretty decent real-time and near-real-time clusters with a fairly rich open API. I doubt these will be affected (and hence the HE app) but as @bptworld was saying we will find out May 10th for sure :grin:

Thanks for the heads-up.

3 Likes

hi sorry where can i find the driver thanks

Either use Hubitat Package Manager (recommended) or go to my GitHub (link in first post) and get the code from there.

hi thanks i have the app code just cant find driver code or is it just the app i need?

There is a driver (Location Tracker User Driver) but I could not find it either at the github site. That said, install Hubitat Package Manager and never have to look for apps/drivers again.

If you found the app code, the driver is in the same spot.

https://github.com/bptworld/Hubitat/tree/master/Ported/Life360

thanks for all your help much appreciated i think i got working now just one more question how do you get dashboard tile to show all the info like yours

Look at the virtual device, once it's populated there. Add it to the dashboard like any other device, just choose the attribute you want to display.

Life360 device attribute called bpt-statusTile1

Thank you

So ive been a big fan of life360. I carry the silver membership

Grandpa rolled his car a few days ago. We got no notifications from life360.

Just a warning for anyone whi may be counting on the crash detection.

Very disappointing

Presence detection has been very unreliable too. The iOS app keeps unloading on iOS 14 on iPhone 12 Pro too.