core icon indicating copy to clipboard operation
core copied to clipboard

the status of the device is not being updated or is being updated incorrectly

Open bisquit2003 opened this issue 2 years ago • 6 comments

The problem

recently, the integration sends devices "home" for a while (about 10-15 minutes), although they are physically far away or does not change the status at all for a long time, although the device is moving I noticed a pattern - this happens if the device is static, does not move anywhere. the distance does not matter, it can be 500m from the home zone and 1000 km (if you flew to another city and the device was offline for a while, did not transmit its coordinates) at this time, everything is correct in the locator app for iPhone the error can be repeated several times, I noticed recently when I was in a cafe more than 1km from home, but the status of the device "jumped" at home/not at home beta versions of ios have not been installed reinstalling the integration and deleting the icloud folder does not solve the problem haos version 22.7.7 does not solve the problem

What version of Home Assistant Core has the issue?

22.8.6

What was the last working version of Home Assistant Core?

No response

What type of installation are you running?

Home Assistant OS

Integration causing the issue

Apple iCloud

Link to integration documentation on our website

No response

Diagnostics information

No response

Example YAML snippet

No response

Anything in the logs that might be useful for us?

No response

Additional information

No response

bisquit2003 avatar Aug 22 '22 12:08 bisquit2003

icloud documentation icloud source (message by IssueLinks)

Hey there @quentame, @nzapponi, mind taking a look at this issue as it has been labeled with an integration (icloud) you are listed as a code owner for? Thanks! (message by CodeOwnersMention)

image for example, here is a story on 3 different integrations of the same device:

  1. Apple iCloud integration
  2. Wi-Fi integration with the home network
  3. integration with the Home Assistant app

bisquit2003 avatar Aug 28 '22 12:08 bisquit2003

I've got the same problem, however it only seems to be impacting my person devices not family ones.

Geoff571 avatar Sep 02 '22 14:09 Geoff571

Same. And update iCloud via service manually won't change a thing.

Mariuss811 avatar Sep 08 '22 13:09 Mariuss811

same for me.. always security issues because the device does not change the state. happens for my iphone and for the family iphones. Also seeing this. If I manually reload the integration once or twice, the info will update, but goes stale pretty quickly again.

Animizio avatar Nov 07 '22 17:11 Animizio

Problem still exists. iPhone got no location update for 7 hours. Only triggering the icloud.update service got the current locations for me.

tiischuu avatar Jan 04 '23 15:01 tiischuu

There hasn't been any activity on this issue recently. Due to the high number of incoming GitHub notifications, we have to clean some of the old issues, as many of them have already been resolved with the latest updates. Please make sure to update to the latest Home Assistant version and check if that solves the issue. Let us know if that works for you by adding a comment 👍 This issue has now been marked as stale and will be closed if no further activity occurs. Thank you for your contributions.

Bump

bcutter avatar Apr 04 '23 18:04 bcutter

Also ran into this. From time to time simply no entities get an update.

What I found in HA log:

grafik

Logger: homeassistant.components.icloud.account
Source: components/icloud/account.py:317
Integration: Apple iCloud (documentation, issues)
First occurred: 11. April 2023 um 11:57:51 (2 occurrences)
Last logged: 10:20:58

Unknown iCloud error: Authentication required for Account. (450)
Unknown iCloud error: HTTPSConnectionPool(host='pXX-fmipweb.icloud.com', port=443): Max retries exceeded with url: /fmipservice/client/web/refreshClient (Caused by NewConnectionError('<urllib3.connection.HTTPSConnection object at 0x7eee5737c0>: Failed to establish a new connection: [Errno -3] Try again'))

I don't get any re-authentication dialogue - nothing in HA, nothing on the iDevices, no mail, nothing...


This "silent death" is really creating serious issues, especially if you rely on GPS based device trackers.

As a workaround I built a "fix automation" containing this:

trigger:
  - platform: state
    entity_id:
      - sensor.iphone_battery_level_icloud #use an entity which regularly updates (is online the most)
    for:
      hours: 2 #adapt to your needs - after this time without an entity update the trigger matches
      minutes: 0
      seconds: 0
action:
  - service: homeassistant.reload_config_entry
    data: {}
    target:
       entity_id: sensor.iphone_battery_level_icloud #just use any entity of the icloud integration
    continue_on_error: true
    enabled: true

This should reload the iCloud integration once there's no entity update for more than 2 hours (which is my current sweet spot for "unusual"). Ugly but... otherwise iCloud integration is completely unusable unfortunately!

bcutter avatar Apr 12 '23 19:04 bcutter

There hasn't been any activity on this issue recently. Due to the high number of incoming GitHub notifications, we have to clean some of the old issues, as many of them have already been resolved with the latest updates. Please make sure to update to the latest Home Assistant version and check if that solves the issue. Let us know if that works for you by adding a comment 👍 This issue has now been marked as stale and will be closed if no further activity occurs. Thank you for your contributions.