Giter VIP home page Giter VIP logo

icloud3_v3's Introduction

iCloud3 v3, Development Version

This repo is used for testing new features and updates to iCloud3 v3. It is not the version of iCloud3 that is available for general use. The general availability version is found on the iCloud3 repo here


CurrentVersion Type HACS

ProjectStage Released

iCloud3 is a device tracker custom component that tracks your iPhones, iPads and Apple Watches. iDevices in the Family Sharing List and the HA Mobile App Integration are trackable. The iDevice requests location data from from Apple's iCloud Location Services and monitors various triggers sent from the Home Assistant Mobile App to Home Assistant. Sensors are updated with the device's location, distance from zones, travel time to zones, etc.

Although AirPods and AirTags are in the iCloud Family Sharing list, they can not be tracked. They do not have the internal components to provide location data using cell towers and gps location information to Apple.

iCloud3 v3 Highlights

Although Home Assistant has it's own official iCloud component, iCloud3 goes far beyond it's capabilities. The important highlights include:

  • HA Integration - iCloud3 is a Home Assistant custom integration that is set up and configured from the HA Settings > Devices & Services > Integrations screen.
  • Configuration Settings - Configuration parameters are updated online using various screens and take effect immediately without restarting HA.
  • Track iPhones, iPads and Apple Watches - Track or monitor your iDevices.
  • Location data sources - Location data comes from the iCloud Account and the HA Mobile App
  • Actively track a device - The device will request it's location on a regular interval based on its distance from Home or another zone.
  • Passively monitor a device - The device does not request it's location. It is updated when another tracked device requests theirs.
  • Waze Route Service - The travel time and distance to Home or another tracked zone is provided by Waze.
  • Waze Route Service History Database - The travel time and distance data from Waze is saved to a local database and reused when the device is in a previous location.
  • Track from multiple zones - Tracking results (location, travel time, distance, arrival time, etc.) are reported from the Home zone or another zone (office, second home, parents, etc.).
  • Primary Home Zone - Set another zone as the primary zone for the device and report tracking results based on that location. This is useful when you have two homes, on a vacation at another location, triggering automations at your parents house with true devices, etc.
  • Improved GPS accuracy - GPS wandering errors leading to incorrect zone exits are eliminated.
  • Monitors Mobile App activity - Looks for location and trigger changes every 5-seconds.
  • Enter Zone delay - Delay processing Zone Enter triggers in case you are just driving through it.
  • Stationary Zone - A dynamic Stationary Zone is created when the device has not moved for a while (doctors office, store, friend's house). This helps conserve battery life.
  • Nearby devices - The distance to other devices is displayed and used to determine tracking results.
  • Zone monitoring - The number of devices in each zone is displayed when a device is updated.
  • Local Time Zone - Event times are normally displayed using the time zone your HA server is in. If, hoowever, you are away from home and in another time zone can, the Event times can be displayed for the time zone you are in.
  • Zone Activity Log - A log can be kept for each time you are in a zone. This log file (.csv format) can be imported into a spreadsheet program and used for expense reporting, travel history, device location monitoring, etc.
  • Sensors and more sensors - Many sensors are created and updated with distance, travel time, polling data, battery status, zone attributes, etc. Select only the ones you want to use.
  • Battery status - Updates the battery level and status (charging/not charging) from iCloud data during a tracking event and from the Mobile App every 5-seconds.
  • Distance Sensor Attributes - Shows the distance to the center and edge of the Home zone, distance to other zones and distance to other devices.
  • Event Log - The current status and event history of every tracked and monitored device is displayed on the iCloud3 Event Log custom Lovelace card. Information about device configuration, errors and alerts, nearby devices, tracking results, debug information and location request results is displayed.
  • Updating and Restarting - iCloud3 can be restarted without restarting Home Assistant.
  • Restore state values on restart - The current device_tracker and sensor entity states are restored on a restart. The attributes are not restored but are reset on the first tracking Event.
  • Device_tracker and sensor entities - iCloud3 devices and sensors are Home Assistant entities that are added, deleted and changed on the Update iCloud3 Devices and Sensors configuration screens.
  • Zone Exits for devices not using the Mobile App - Devices that do not or can not (Apple Watch) use the Mobile App respond to a zone exit when it detects another nearby device has left a zone.
  • Extensive Documentation - The iCloud3 User Guide explains the three main components, hot to get started, how to migrate from v2, how to install the integration, each of the screens and special features, the service calls that can request updates, locate iPhones and send notification alerts, examples of how to automate opening your garage door when you arrive home, etc.
  • And More - Review the following documentation to see if it will help you track and monitor the locations of your iPhones, iPads and Apple Watches.

Tracking Information Screen with Event Log

The screens below are an example of how the many tracking sensors can be displayed. The screen on the left shows the current tracking formation for Gary while the Event Log on the right shows a history of important tracking events.

evlimg

iCloud3 Documentation

  • Introduces the many features and components of iCloud3
  • Describes how to migration from v2.4.7 to v3.0
  • Provides step-by-step to install and configure iCloud3, it's components and it's supporting components (iCloud Account and the Mobile App)
  • Highlights the configuration screens and parameters
  • Provides example screens, automations and scripts
  • The User Guide is here

Installing or Upgrading to iCloud3 v3

  • iCloud3 v3 is now available on the iCloud3 HACS base as a prerelease version.

Important Links

  • iCloud3 v3 User Guide -The User Guide is quite extensive and can be found here
  • iCloud3 v3 GitHub Repository (Prerelease Version) - The primary GitHub Repository is here
  • iCloud3 v3 Development GitHub Repository - The Development Repository is used for beta version changes that have not been released yet is here
  • Installing as a New Installation - iCloud3 v3 is available in HACS as a prerelease version. Installation instructions are here
  • Migrating from v2.4.x - This includes installing iCloud3 v3, migrating your current configuration and reviewing it to insure it was migrated correctly. Instructions are here

Gary Cobb, aka GeeksterGary

icloud3_v3's People

Contributors

gcobb321 avatar kurim avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

icloud3_v3's Issues

Typo in iCloud_v3_beta5

'/config/custom_components/icloud3/event_log_cad/ipad.png'

must be

'/config/custom_components/icloud3/event_log_card/ipad.png'

2022-12-29 09:16:46.224 ERROR (SyncWorker_7) [icloud3] [Errno 2] No such file or directory: '/config/custom_components/icloud3/event_log_cad/ipad.png'
Traceback (most recent call last):
  File "/config/custom_components/icloud3/support/start_ic3.py", line 724, in _copy_image_files_to_www_directory
    shutil.copy(image_filename, www_evlog_directory)
  File "/usr/local/lib/python3.10/shutil.py", line 417, in copy
    copyfile(src, dst, follow_symlinks=follow_symlinks)
  File "/usr/local/lib/python3.10/shutil.py", line 254, in copyfile
    with open(src, 'rb') as fsrc:
FileNotFoundError: [Errno 2] No such file or directory: '/config/custom_components/icloud3/event_log_cad/ipad.png'

When change it manual and restart HA I have no errors at all anymore :)

Battery sensors for FmF devices

When setting up an FmF device, it creates the sensor entities for Battery and BatteryStatus, even though this info isn't available for FmF devices.

I tried disabling these entities, but they seem to be re-enabled later.

Can we either have the ability to disable them and keep them disabled, or not create them in the first place if it's an FmF device?

Thanks

I've tried disabling the battery entities for the 2 FmF devices, but they are re-enabled on HA restart.

FmF devices do not report battery level. Trying to disable these entities so that they don't show up in low-battery notifications, etc.

I've tried disabling the battery entities for the 2 FmF devices, but they are re-enabled on HA restart.

Originally posted by @derekoharrow in #27 (comment)

It appears that iCloud3 is re-enabling/re-creating entities on HA restart and overwriting entities that are disabled.

iCloud v3 Beta Testers List - Latest: Beta 14 (3/9/2923)

Beta 14 was just released

Download it from the Release page here. Select Assets, then select icloud3-beta-#.zip)

New Testers

Please add your username to this thread so I can easily notify you of any updates. Also add a comment to this Issue. Then you will be notified when a new version is available. It will also help me keep track of who is testing it and the number of people that are giving it a try.

Do not download from HACS. The beta is not available on HACS. If you download from HACS, v2.4.7 will overwrite the iCloud3 directory, wiping out the v3 beta and you will have to start over.

Important Links

  • iCloud3 v3 Documentation can be found here
  • Download from the Release page here. Select Assets, then select icloud3-beta-#.zip. or,
  • All of the Change Logs can be found here

I'll post a notice to this Issue when a new beta version is available. I'll add it to the bottom of this Issue and it will list of what changed.

Thanks
Gary.

patform: icloud3 statement

I'm seeing this in the logs, but for the life of me i cannot find anywhere in my config files a platform: icloud3 statement and i have deleted the config_ic3.yaml file. not a big issue, just a bit confusing.

This error originated from a custom integration.

Logger: icloud3
Source: custom_components/icloud3/device_tracker.py:48
Integration: iCloud3 Device Tracker (documentation, issues)
First occurred: 11:21:44 AM (1 occurrences)
Last logged: 11:21:44 AM

ICLOUD3 ALERT: The HA configuration.yaml file contains a PLATFORM: ICLOUD3 statement. iCloud3 v3 is now an integration and does not use the configuration.yaml or config_ic3.yam files. 1. Remove PLATFORM: ICLOUD3 statements from configuration.yaml. 2. Restart Home Assistant 3. Add iCloud3 on the Devices & Settings > Integrations screen 4. Configure iCloud3 on the Integrations screen 5. Restart iCloud3

Findy my phone not executable

If i try to use the service find my phone from the lovelace card, the service is not running because of:"'PyiCloud_FamilySharing' object is not callable". If I set up an script like given in the docs the same error occurs.

"None" error

getting the following error on my setup. Home Assistant 2023.1.0b5
Latest icloud3_v3 version

Deze fout is ontstaan door een aangepaste integratie.

Logger: icloud3
Source: custom_components/icloud3/support/event_log.py:328
Integration: iCloud3 Device Tracker (documentation, issues)
First occurred: 12:05:07 (11 occurrences)
Last logged: 16:47:39

None
Traceback (most recent call last):
  File "/config/custom_components/icloud3/support/event_log.py", line 328, in update_event_log_display
    self.evlog_attrs['fname']      = self.fname_selected = self.devicename_by_fnames[devicename]
KeyError: None

I am having some basic issue getting the component to work.

I have installed everything and set up one device. However....

STAGE 4 > SETUP ICLOUD & IOSAPP TRACKING METHODS, RETRYING ICLOUD DEVICE SETUP
UNTRACKABLE DEVICE ALERT > DEVICES ARE NOT BEING TRACKED:
•HANS_IPHONE_ICLOUD, HANS IPHONE ICLOUD/IPHONE
━━━━━━━━━━━━━━━━━━━━
THIS CAN BE CAUSED BY:
•ICLOUD3 DEVICE CONFIGURATION ERROR -- NO ICLOUD (FAMSHR/FMF) DEVICE AND NO IOS APP DEVICE HAVE BEEN SELECTED, OR

chrome_m68NrfYH8z

And for some reason my lovelace card look like this (event log is not loading)

chrome_fWGEM3uGxl

Won't start

I can't even get beta 2 to start, I get the following error:

Logger: homeassistant.config_entries
Source: helpers/entity_component.py:166
First occurred: 2:32:13 PM (1 occurrences)
Last logged: 2:32:13 PM

Error setting up entry iCloud3 for device_tracker
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/config_entries.py", line 372, in async_setup
    result = await component.async_setup_entry(hass, self)
  File "/usr/src/homeassistant/homeassistant/components/device_tracker/config_entry.py", line 44, in async_setup_entry
    return await component.async_setup_entry(entry)
  File "/usr/src/homeassistant/homeassistant/helpers/entity_component.py", line 166, in async_setup_entry
    raise ValueError("Config entry has already been setup!")
ValueError: Config entry has already been setup!

and all my devices show "• • Starting iCloud3 • •"

Not prompted for 2FA code ? cannot autenticate ?

Hi,

I'm getting....

2023-01-17 08:46:55.821 ERROR (SyncWorker_4) [icloud3] * iCloud3 Error from iCloud Loc Svcs > Error Authenticating account or no data was returned from iCloud Location Services. iCloud access may be down or the Username/Password may be invalid.

I've checked username and password, tried the reset and reautheenticate option.
I've tried to switch on debug logging, but not sure if that goes into the main log, or another log file that I cannot find.

Thoughts ?

2FA does work normally (6 digit code) if I log in through a web browser to icloud.com.

Feature Request - distance between devices

Hi, loving IC3v3 so far!

In the attributes for the device_tracker entities, it has an attribute of "Distance To", showing the distance from that device tracker to the other device trackers.

This is really useful info as it enables you to tell if two people are near each other. For example, I don't want certain actions to happen if my wife and I are together, etc.

Could you expose these as separate individual attributes perhaps to make them easier to consume? Or perhaps create different entities to track the distance between specific trackers?

Thanks

Stuck on initializing and can't use event log card

Your latest update has gotten me to the point where I can pull in the devices and configure them, however ic3 still shows as initializing.
image

I also can't use the event log reader card and get the following error in my HA logs.

2023-01-17 13:40:19.930 ERROR (MainThread) [frontend.js.latest.202301100] https://ha.broyuken.com/hacsfiles/icloud3/icloud3-event-log-card.js?v=1.000:1465:38 TypeError: can't convert undefined to object
2023-01-17 13:40:20.676 ERROR (MainThread) [homeassistant] Error doing job: Exception in callback _SelectorDatagramTransport._read_ready()
Traceback (most recent call last):
File "/usr/local/lib/python3.10/asyncio/events.py", line 80, in _run
self._context.run(self._callback, *self._args)
File "/usr/local/lib/python3.10/asyncio/selector_events.py", line 1027, in _read_ready
self._protocol.datagram_received(data, addr)
File "/config/custom_components/localtuya/discovery.py", line 70, in datagram_received
self.device_found(decoded)
File "/config/custom_components/localtuya/discovery.py", line 79, in device_found
self._callback(device)
File "/config/custom_components/localtuya/__init__.py", line 105, in _device_discovered
entry = async_config_entry_by_device_id(hass, device_id)
File "/config/custom_components/localtuya/common.py", line 126, in async_config_entry_by_device_id
if device_id in entry.data[CONF_DEVICES]:
KeyError: 'devices'

Can't update Route Server Location

Can't change the Waze Route Server location for my location (Brazil). It keeps saying my correct location is US/Canada. And there is a log stating that no data returned using US/Canada

image

image

Family share with a iPhone without HA app

Hi,

Beta 2 is running much better. My own iPhone is working. See all the sensors etc.
But my partners iPhone isn't coming up at all. He doesn't have HA app installed.
So the information but be come from my iCloud account with family share.
(this worked great with iCloud3_v2)

------------------------------------------------------------------------------------------------------------------------
09:52:25	   Initializing iCloud3 v3.0.0b2 > Monday, Dec 19
09:52:25	   Set Up Waze > Region-EU, MinDist-10km, MaxDist-500km, Realtime-True, HistoryDatabaseUsed-True
09:52:25	   Waze History Database > Compressed, Record Count-0
09:52:25	   Configure iCloud3 Operations >, •Load configuration parameters, •Set Display Text As Fields (0 used), •Se
					t Default Tracking Method (FamShr), •Initialize Debug Control (info), •Set Unit of Measure Formats (
09:52:29	   AUTHENTICATE PyiCloud, [email protected], init
09:52:29	   ADDED FamShr PyiCloudDevice-, Apple Watch van Peter/QkKnPAD4aj
09:52:29	   NO LOCATION FamShr PyiCloudData-Peter’s MacBook Pro
09:52:29	   ADDED FamShr PyiCloudDevice-, iMac van Peter/2DdaH7FTtm
09:52:29	   ADDED FamShr PyiCloudDevice-, Peter iPhone/5yAbrrC4uE
09:52:29	   NO LOCATION FamShr PyiCloudData-cenkay’s iPhone
09:52:29	   NO LOCATION FamShr PyiCloudData-cenkay’s iPhone
09:52:29	   NO LOCATION FamShr PyiCloudData-iPhone
09:52:29	   ADDED FamShr PyiCloudDevice-, Cenkay 13/nA/v6NXyDu
09:52:29	   ADDED FamShr PyiCloudDevice-, AirPods van Cenkay/nKz8eqmhd1
09:52:29	   CREATED PyiCloud FamShr, [email protected], init
09:52:29	   ADDED FmF PyiCloudDevice, (Njc5MTcz)
09:52:29	   ADDED FmF PyiCloudDevice, (MTc0MjY2)
09:52:29	   CREATED PyiCloud FmF, [email protected], init
09:52:29	   iCloud Account Authenticated (#1) > LastAuth-Never (Initializing), Method-Account/PasswordSignin, Took-4 
					sec
09:52:29	   iCloud Location Services interface > Verified

Cannot choose a zone other than home when zones defined in yaml

Hi,

I want to track some devices back to a different zone, not home.
I have multiple home assistant zones setup, but I cannot choose them from the config flow in home assistant ?
Am I missing something?

Great work on the config screens btw, definitely the most complex config flow screens I have ever seen !!

Location updates slow

Not sure if it is a configuration issue or something else, but it seems that my devices don't update nearly as fast on v3 as compared to v2. the reason i noticed is when i take the dogs for a stroll, i would get a notification that i left home almost as soon as i was about a block away from the house. now that same alert does not happen until about 6-7 blocks away. Not sure what I can look at to see what may be causing the issue.

Errors updating devices

In the Integration menu, I'm going into ICLOUD3 DEVICES to edit my devices. When I do I get this in the HASS log:

2023-01-13 17:29:38.714 ERROR (MainThread) [icloud3] list index out of range
Traceback (most recent call last):
  File "/config/custom_components/icloud3/config_flow.py", line 2329, in _build_opt_picture_filename_list
    if file.rsplit('.', 1)[1] in image_extensions:
IndexError: list index out of range

When on the device screen, I'm seeing the message:

Check the FamShr, FmF, iOS App or Picture parameter value (Not found or Invalid). Reset to None``

However, everything is setup as it's supposed to be - iOS App, FmF and FamShr are all set correctly. Changing them and saving again doesn't seem to make any difference.

Error log in HA (iCloud3_Beta3)

I see 2 times this error. Then no errors again (I have 2 iPhones in the integration)

2022-12-21 17:58:37.022 ERROR (SyncWorker_2) [icloud3] 'notify'
Traceback (most recent call last):
  File "/config/custom_components/icloud3/support/iosapp_interface.py", line 128, in get_mobile_app_notifications
    notify_services = dict(services.__dict__)['_services']['notify']
KeyError: 'notify'

Battery Sensors stop updating, conflict between Info sensor and Battery sensor

I noticed a problem that the sensors stop updating after a few / several hours and the indicated data is incorrect.

I'm using icloud3-beta-7.
HA version: 2023.1.2.

Screenshot 2023-01-11 at 08 37 44
Here we can see, that info was be updated at 7:56, but this iPhone already has battery at around 80% since 7:00, also it's away from home from around 7:20. Zone is home, but it's showing 6,7 km distance and travel time 13 minutes to home?

Screenshot 2023-01-11 at 08 39 36

Here there is battery history, it show that it was updated 43 minutes age, when iPhone was already charged.

Screenshot 2023-01-11 at 08 40 05

Another iPhone not updated from yesterday:
Screenshot 2023-01-11 at 08 38 14

Screenshot 2023-01-11 at 08 38 28

Screenshot 2023-01-11 at 08 39 02

Event log doesn't show any errors:
Screenshot 2023-01-11 at 08 40 43

Screenshot 2023-01-11 at 08 41 01

Debug log doesn't show any errors, just stops updating?
icloud3-debug.log
Config file with erased login/password/famshr_device_id:
configuration_clean.txt

When I restart iCloud3 everything is starting to work for couple of hours.

Data not accurate

Hi all,

I checked If the data that has been received is accurate. Its not. My friend is at Ziggo Dome for BlackPink Concert but his location is still at his work. I check find my friends and live view is in Ziggo Dome.

The information from iCloud3 is still at his work...

new log file not being created per the new behavior definitions.

Per the beta 4 log file rework...
Reworked the icloud3-debug.log file:

  • A new file is created when:
  1. HA/iCloud3 starts and the Log Level is debug or rawdata or
  2. Starting Debug Logging from Event Log > Actions or
  3. At midnight when debug logging is on and the file is more thn 20-hours old.
  • Otherwise debug records are added to the existing Debug Log file.
  • If the Log Level is debug or rawdata in the Configurator > Event Log parameters and
    Stop Debug Logging was selected on Event Log > Actions, the ic3 config will be changed
    to 'info' (no debug logging).
  • If the configuration is set to 'info' (no debug logging) and it is started on
    Event Log > Actions, the configuration is not updated and the debug logging will
    remain on until midnight, the next iCloud3 restart or when it is turned off.

In Beta5 I can't seem to cause a new log file to be created by either method 1 or 2 from above. It seems as if a new log file will not be replaced until it is at least 20 hours old and midnight has passed.

[icloud3] 'NoneType' object has no attribute 'model'

I see those error lines in HA log.

Home Assistant 2022.12.7
Supervisor 2022.11.2
Operating System 9.4
Frontend 20221213.1 - latest

2022-12-18 10:30:30.295 ERROR (MainThread) [icloud3] 'NoneType' object has no attribute 'model'
Traceback (most recent call last):
  File "/config/custom_components/icloud3/helpers/entity_io.py", line 137, in get_entity_registry_data
    raw_model = device_reg_data.model
AttributeError: 'NoneType' object has no attribute 'model'
2022-12-18 10:30:30.297 ERROR (MainThread) [icloud3] 'NoneType' object has no attribute 'model'
Traceback (most recent call last):
  File "/config/custom_components/icloud3/helpers/entity_io.py", line 137, in get_entity_registry_data
    raw_model = device_reg_data.model
AttributeError: 'NoneType' object has no attribute 'model'
2022-12-18 10:30:30.300 ERROR (MainThread) [icloud3] 'NoneType' object has no attribute 'model'
Traceback (most recent call last):
  File "/config/custom_components/icloud3/helpers/entity_io.py", line 137, in get_entity_registry_data
    raw_model = device_reg_data.model
AttributeError: 'NoneType' object has no attribute 'model'
2022-12-18 10:30:30.302 ERROR (MainThread) [icloud3] 'NoneType' object has no attribute 'model'
Traceback (most recent call last):
  File "/config/custom_components/icloud3/helpers/entity_io.py", line 137, in get_entity_registry_data
    raw_model = device_reg_data.model
AttributeError: 'NoneType' object has no attribute 'model'
2022-12-18 10:30:30.305 ERROR (MainThread) [icloud3] 'NoneType' object has no attribute 'model'
Traceback (most recent call last):
  File "/config/custom_components/icloud3/helpers/entity_io.py", line 137, in get_entity_registry_data
    raw_model = device_reg_data.model
AttributeError: 'NoneType' object has no attribute 'model'
2022-12-18 10:30:30.307 ERROR (MainThread) [icloud3] 'NoneType' object has no attribute 'model'
Traceback (most recent call last):
  File "/config/custom_components/icloud3/helpers/entity_io.py", line 137, in get_entity_registry_data
    raw_model = device_reg_data.model
AttributeError: 'NoneType' object has no attribute 'model'
2022-12-18 10:30:30.309 ERROR (MainThread) [icloud3] 'NoneType' object has no attribute 'model'
Traceback (most recent call last):
  File "/config/custom_components/icloud3/helpers/entity_io.py", line 137, in get_entity_registry_data
    raw_model = device_reg_data.model
AttributeError: 'NoneType' object has no attribute 'model'
2022-12-18 10:30:30.312 ERROR (MainThread) [icloud3] 'NoneType' object has no attribute 'model'
Traceback (most recent call last):
  File "/config/custom_components/icloud3/helpers/entity_io.py", line 137, in get_entity_registry_data
    raw_model = device_reg_data.model
AttributeError: 'NoneType' object has no attribute 'model'
2022-12-18 10:30:30.315 ERROR (MainThread) [icloud3] 'NoneType' object has no attribute 'model'
Traceback (most recent call last):
  File "/config/custom_components/icloud3/helpers/entity_io.py", line 137, in get_entity_registry_data
    raw_model = device_reg_data.model
AttributeError: 'NoneType' object has no attribute 'model'
2022-12-18 10:30:30.316 ERROR (MainThread) [icloud3] 'NoneType' object has no attribute 'model'
Traceback (most recent call last):
  File "/config/custom_components/icloud3/helpers/entity_io.py", line 137, in get_entity_registry_data
    raw_model = device_reg_data.model
AttributeError: 'NoneType' object has no attribute 'model'
2022-12-18 10:30:30.539 ERROR (MainThread) [aiohttp.server] Error handling request
Traceback (most recent call last):
  File "/usr/local/lib/python3.10/site-packages/aiohttp/web_protocol.py", line 435, in _handle_request
    resp = await request_handler(request)
  File "/usr/local/lib/python3.10/site-packages/aiohttp/web_app.py", line 504, in _handle
    resp = await handler(request)
  File "/usr/local/lib/python3.10/site-packages/aiohttp/web_middlewares.py", line 117, in impl
    return await handler(request)
  File "/usr/src/homeassistant/homeassistant/components/http/security_filter.py", line 60, in security_filter_middleware
    return await handler(request)
  File "/usr/src/homeassistant/homeassistant/components/http/forwarded.py", line 100, in forwarded_middleware
    return await handler(request)
  File "/usr/src/homeassistant/homeassistant/components/http/request_context.py", line 28, in request_context_middleware
    return await handler(request)
  File "/usr/src/homeassistant/homeassistant/components/http/ban.py", line 81, in ban_middleware
    return await handler(request)
  File "/usr/src/homeassistant/homeassistant/components/http/auth.py", line 236, in auth_middleware
    return await handler(request)
  File "/usr/src/homeassistant/homeassistant/components/http/view.py", line 136, in handle
    result = await result
  File "/usr/src/homeassistant/homeassistant/components/config/config_entries.py", line 241, in post
    return await super().post(request, flow_id)
  File "/usr/src/homeassistant/homeassistant/components/http/data_validator.py", line 73, in wrapper
    result = await method(view, request, data, *args, **kwargs)
  File "/usr/src/homeassistant/homeassistant/helpers/data_entry_flow.py", line 110, in post
    result = await self._flow_mgr.async_configure(flow_id, data)
  File "/usr/src/homeassistant/homeassistant/data_entry_flow.py", line 281, in async_configure
    result = await self._async_handle_step(
  File "/usr/src/homeassistant/homeassistant/data_entry_flow.py", line 368, in _async_handle_step
    result: FlowResult = await getattr(flow, method)(user_input)
  File "/config/custom_components/icloud3/config_flow.py", line 556, in async_step_menu
    return await self.async_step_device_list()
  File "/config/custom_components/icloud3/config_flow.py", line 1512, in async_step_device_list
    self._build_device_form_selection_lists()
  File "/config/custom_components/icloud3/config_flow.py", line 1998, in _build_device_form_selection_lists
    self._build_opt_famshr_devices_list()
  File "/config/custom_components/icloud3/config_flow.py", line 2012, in _build_opt_famshr_devices_list
    devices_desc = start_ic3.get_famshr_devices(self.PyiCloud)
  File "/config/custom_components/icloud3/support/start_ic3.py", line 1315, in get_famshr_devices
    Gb.PyiCloud.FindMyFriends.refresh_client()
AttributeError: 'NoneType' object has no attribute 'refresh_client'

Still can't do anything with this

I have the newest release version installed, but when I go to update device in the menu, I get "Unknown error occurred" No errors in the logs, but I can't do anything.

Having trouble getting beta to function

I started by trying to upgrade from v2.4 to v3 beta 6, but found it problematic, so I've started from scratch - wiping the existing setup, installing the v6 beta, and setting up from scratch.

I have 6 devices to monitor, my own which uses my Apple ID, 3 devices on Family Sharing and 2 on Find My Friends.

I've set all these up and from the logs (see below) these are being found ok, but the locations aren't updating correctly. I've tried a few times, and sometimes I can get some of them to update (the FamShr one's, but not FmF). It seems to be sticking at Stage 6

Any suggestions where to start debugging?

2023-01-02 21:27:21 [pyicloud:0168]  iCloud Account Authenticated (#1) > LastAuth-Never (Initializing), Method-Account/PasswordSignin, Took-6 sec
2023-01-02 21:27:21 [pyicloud:0068]  iCloud Location Services interface > Verified
2023-01-02 21:27:24 [device_t:0189]  Device Tracker entity created: device_tracker.alans_iphone_ic3, #1
2023-01-02 21:27:24 [device_t:0189]  Device Tracker entity created: device_tracker.lindseys_iphone_ic3, #2
2023-01-02 21:27:24 [device_t:0189]  Device Tracker entity created: device_tracker.laurens_iphone_ic3, #3
2023-01-02 21:27:24 [device_t:0189]  Device Tracker entity created: device_tracker.dereks_iphone_ic3, #4
2023-01-02 21:27:24 [device_t:0189]  Device Tracker entity created: device_tracker.ryans_iphone_ic3, #5
2023-01-02 21:27:24 [device_t:0189]  Device Tracker entity created: device_tracker.sylvies_iphone_ic3, #6
2023-01-02 21:27:24 [device_t:0087]  Device Tracker entities created: 6
2023-01-02 21:27:24 [__init__:0167]  START iCloud3 Initial Load Executor Job (start_icloud3)
2023-01-02 21:27:24 [start_ic:0056]  STAGE 1 >  iCloud3 Directory > /config/custom_components/icloud3
2023-01-02 21:27:24 [start_ic:0060]  STAGE 1 >  iCloud3 Configuration File > /config/.storage/icloud3/configuration
2023-01-02 21:27:24 [start_ic:1923]  STAGE 1 >  iCloud3 is an HA Integration. Delete the 'platform: icloud3` configuration parameters in the HA `configuration.yaml` file.
2023-01-02 21:27:24 [start_ic:0612]  STAGE 1 >  iCloud3 Event Log >
                                                                                                        •Current Version Installed-v3.0.1
                                                                                                        •File-/config/www/custom_cards/icloud3-event-log-card.js
2023-01-02 21:27:24 [start_ic:0066]  STAGE 1 >  LocationInfo-{'country_code': 'GB', 'region_code': 'ENG', 'zip_code': 'EN1', 'region_name': 'England', 'city': 'Enfield', 'time_zone': 'Europe/London', 'latitude': 51.6539, 'longitude': -0.0888, 'use_metric': True}
2023-01-02 21:27:24 [time_uti:0437]  STAGE 1 >  Local Time Zone Offset > UTC+00:00 hrs, GMT
2023-01-02 21:27:24 [start_ic:0071]  STAGE 1 >  Stage 1 > Initial Preparations
2023-01-02 21:27:25 [start_ic:0802]  STAGE 2 >  ADDED Zone-london
2023-01-02 21:27:26 [start_ic:0802]  STAGE 2 >  ADDED Zone-opv
2023-01-02 21:27:26 [start_ic:0802]  STAGE 2 >  ADDED Zone-home
2023-01-02 21:27:26 [start_ic:0840]  STAGE 2 >  Set up Zones (zone/fname) >
                                                                                                        •puregym_2/Puregym2 (r88m)
                                                                                                        •london/London (r6000m)
                                                                                                        •puregym_1/Puregym1 (r52m)
                                                                                                        •home/Home (r100m)
2023-01-02 21:27:26 [start_ic:0858]  STAGE 2 >  Stationary Zone Base Information > BaseLocation-(51.67044, -0.07011), Radius-200m, DistFromHome-1.0km, MinDistFromZone-200m, DistMoveLimit-150m
2023-01-02 21:27:26 [waze....:0061]  STAGE 2 >  Set Up Waze > Region-US, MinDist-1km, MaxDist-1000km, Realtime-False, HistoryDatabaseUsed-True
2023-01-02 21:27:26 [waze_his:0177]  STAGE 2 >  > Waze History Database > /config/.storage/icloud3/waze_location_history.db
2023-01-02 21:27:26 [waze_his:0492]  STAGE 2 >  Waze History Database > Compressed, Record Count-0
2023-01-02 21:27:26 [start_ic:0096]  STAGE 2 >  Stage 2 > Prepare Support Services
2023-01-02 21:27:27 [device..:0486]  STAGE 3 >  ADDED DeviceFmZone-alans_iphone_ic3:home
2023-01-02 21:27:27 [device..:0486]  STAGE 3 >  ADDED DeviceFmZone-alans_iphone_ic3:opv
2023-01-02 21:27:27 [start_ic:0964]  STAGE 3 >  ADDED Device-alans_iphone_ic3
2023-01-02 21:27:27 [start_ic:0985]  STAGE 3 >  ✓ alans_iphone_ic3 > Alan's iPhone (IC3)/iPhone (Tracked)
                                                                                                        ◦FamShr Device: None
                                                                                                        ◦FmF Device: [email protected]
                                                                                                        ◦iOSApp Entity: NotMonitored
                                                                                                        ◦Primary 'Home' Zone: Opv
                                                                                                        ◦Track from Zones: home, opv
2023-01-02 21:27:27 [device..:0486]  STAGE 3 >  ADDED DeviceFmZone-lindseys_iphone_ic3:home
2023-01-02 21:27:27 [start_ic:0964]  STAGE 3 >  ADDED Device-lindseys_iphone_ic3
2023-01-02 21:27:27 [start_ic:0985]  STAGE 3 >  ✓ lindseys_iphone_ic3 > Lindsey's iPhone (IC3)/iPhone (Tracked)
                                                                                                        ◦FamShr Device: Lindsey's iPhone
                                                                                                        ◦FmF Device: XXXXXXXXXXXX
                                                                                                        ◦iOSApp Entity: lindseys_iphone_app
2023-01-02 21:27:27 [device..:0486]  STAGE 3 >  ADDED DeviceFmZone-laurens_iphone_ic3:home
2023-01-02 21:27:27 [start_ic:0964]  STAGE 3 >  ADDED Device-laurens_iphone_ic3
2023-01-02 21:27:27 [start_ic:0985]  STAGE 3 >  ✓ laurens_iphone_ic3 > Lauren's iPhone (IC3)/iPhone (Tracked)
                                                                                                        ◦FamShr Device: Lauren's iphone
                                                                                                        ◦FmF Device: XXXXXXXXXXXXXXX
                                                                                                        ◦iOSApp Entity: laurens_iphone_app
2023-01-02 21:27:27 [device..:0486]  STAGE 3 >  ADDED DeviceFmZone-dereks_iphone_ic3:home
2023-01-02 21:27:27 [start_ic:0964]  STAGE 3 >  ADDED Device-dereks_iphone_ic3
2023-01-02 21:27:27 [start_ic:0985]  STAGE 3 >  ✓ dereks_iphone_ic3 > Derek's iPhone (IC3)/iPhone (Tracked)
                                                                                                        ◦FamShr Device: Derek's iPhone
                                                                                                        ◦FmF Device: None
                                                                                                        ◦iOSApp Entity: dereks_iphone_app
2023-01-02 21:27:27 [device..:0486]  STAGE 3 >  ADDED DeviceFmZone-ryans_iphone_ic3:home
2023-01-02 21:27:27 [start_ic:0964]  STAGE 3 >  ADDED Device-ryans_iphone_ic3
2023-01-02 21:27:27 [start_ic:0985]  STAGE 3 >  ✓ ryans_iphone_ic3 > Ryan's iPhone (IC3)/iPhone (Tracked)
                                                                                                        ◦FamShr Device: iPhone X
                                                                                                        ◦FmF Device: XXXXXXXXXXX
                                                                                                        ◦iOSApp Entity: iphone_x
2023-01-02 21:27:27 [device..:0486]  STAGE 3 >  ADDED DeviceFmZone-sylvies_iphone_ic3:home
2023-01-02 21:27:27 [device..:0486]  STAGE 3 >  ADDED DeviceFmZone-sylvies_iphone_ic3:opv
2023-01-02 21:27:27 [start_ic:0964]  STAGE 3 >  ADDED Device-sylvies_iphone_ic3
2023-01-02 21:27:27 [start_ic:0985]  STAGE 3 >  ✓ sylvies_iphone_ic3 > Sylvie's iPhone (IC3)/iPhone (Tracked)
                                                                                                        ◦FamShr Device: None
                                                                                                        ◦FmF Device: [email protected]
                                                                                                        ◦iOSApp Entity: NotMonitored
                                                                                                        ◦Primary 'Home' Zone: Opv
                                                                                                        ◦Track from Zones: home, opv
2023-01-02 21:27:27 [waze_his:0320]  STAGE 3 >  > WazeHistDB > Get Record, Table-zones, Criteria-entity_id='home', Zone-1 (home)
2023-01-02 21:27:27 [waze_his:0320]  STAGE 3 >  > WazeHistDB > Get Record, Table-zones, Criteria-entity_id='cb5e44', Zone-2 (opv)
2023-01-02 21:27:27 [start_ic:0156]  STAGE 3 >  Stage 3 > Prepare Configured Devices
2023-01-02 21:27:27 [start_ic:0172]  STAGE 4 >  iCloud Account Used > de...@oh...........
2023-01-02 21:27:27 [start_ic:0176]  STAGE 4 >  iCloud Location Services Interface > Started during iCloud3 initialization completed successfully
2023-01-02 21:27:27 [start_ic:1165]  STAGE 4 >  Family Sharing List devices >
                                                                                                        •AirPods → Not Tracked, AirPods (AirPods8194)
                                                                                                        •AirPods #2 → Not Tracked, AirPods (AirPods8211)
                                                                                                        •AirPods Max → Not Tracked, AirPods Max (AirPods8202)
                                                                                                        •Derek's Apple Watch → Not Tracked, Apple Watch 8 (Watch6,15)
                                                                                                        •Derek's iPad → Not Tracked, iPad Pro (iPad8,9)
                                                                                                        ✓Derek's iPhone → dereks_iphone_ic3, iPhone 13 Pro (iPhone14,2)
                                                                                                        ✓Lauren's iphone → laurens_iphone_ic3, iPhone 13 (iPhone14,5)
                                                                                                        •Lindsey's Apple Watch → Not Tracked, Apple Watch 8 (Watch6,14)
                                                                                                        •Lindsey's iPad → Not Tracked, iPad Air (iPad13,1)
                                                                                                        ✓Lindsey's iPhone → lindseys_iphone_ic3, iPhone 12 (iPhone13,2)
                                                                                                        •Ryan's Airpods → Not Tracked, AirPods Pro (AirPods8206)
                                                                                                        ✪Ryan's Airpods → Not Tracked, AirPods Pro (AirPods8206)
                                                                                                        •iPad → Not Tracked, iPad Air (iPad13,1)
                                                                                                        ✓iPhone X → ryans_iphone_ic3, iPhone X (iPhone10,6)
                                                                                                        •lauren's airpods :) → Not Tracked, AirPods (AirPods8207)
2023-01-02 21:27:27 [start_ic:1295]  STAGE 4 >  Find-My-Friends devices >
                                                                                                        ✓lauren@XXXXXX → laurens_iphone_ic3, iPhone
                                                                                                        ✓lindsey@XXXXXXX → lindseys_iphone_ic3, iPhone
                                                                                                        ✓alan@XXXXXXXXXXXXXXX → alans_iphone_ic3, iPhone
                                                                                                        ✓ryan@XXXXXXXX → ryans_iphone_ic3, iPhone
                                                                                                        ✓sylvie@XXXXXXXXX → sylvies_iphone_ic3, iPhone
2023-01-02 21:27:27 [start_ic:1508]  STAGE 4 >  Set PyiCloud Device Id > alans_iphone_ic3, TrkMethod-fmf,
                                                                                                        FamShr-(None), FmF-(#MTAxMzk4)
2023-01-02 21:27:27 [start_ic:1508]  STAGE 4 >  Set PyiCloud Device Id > lindseys_iphone_ic3, TrkMethod-famshr,
                                                                                                        FamShr-(#13MeRWlK), FmF-(#MTYxMTY1)
2023-01-02 21:27:27 [start_ic:1508]  STAGE 4 >  Set PyiCloud Device Id > laurens_iphone_ic3, TrkMethod-famshr,
                                                                                                        FamShr-(#nA/v6NXy), FmF-(#MTkyMTk0)
2023-01-02 21:27:27 [start_ic:1508]  STAGE 4 >  Set PyiCloud Device Id > dereks_iphone_ic3, TrkMethod-famshr,
                                                                                                        FamShr-(#5yAbrrC4), FmF-(None)
2023-01-02 21:27:27 [start_ic:1508]  STAGE 4 >  Set PyiCloud Device Id > ryans_iphone_ic3, TrkMethod-famshr,
                                                                                                        FamShr-(#/7cSXkqO), FmF-(#MTkyMTk0)
2023-01-02 21:27:27 [start_ic:1508]  STAGE 4 >  Set PyiCloud Device Id > sylvies_iphone_ic3, TrkMethod-fmf,
                                                                                                        FamShr-(None), FmF-(#MTA4OTY2)
2023-01-02 21:27:27 [start_ic:1515]  STAGE 4 >  PyiCloud Devices > Derek’s iPad/n6ofM9CX-FamShr, Derek’s Apple Watch/QkKnPAD4-FamShr, Derek’s iPhone/5yAbrrC4-FamShr, Ryan’s Airpods/RBdipW9A-FamShr, iPhone X//7cSXkqO-FamShr, iPad/13MeRWlK-FamShr, Ryan’s Airpods/MiHeDNwr-FamShr, AirPods Max/OqRTaBqb-FamShr, lauren’s airpods :)/AUR58oTO-FamShr, Lauren’s iphone/nA/v6NXy-FamShr, Lindsey’s iPad/13MeRWlK-FamShr, AirPods/UBLGfN7K-FamShr, Lindsey's iPhone/13MeRWlK-FamShr, AirPods #2/EYYvV6Tn-FamShr, Lindsey’s Apple Watch/TPPi0To/-FamShr, /MTkyMTk0-FmF, /MTYxMTY1-FmF, /MTA4OTY2-FmF, /MTkyMTk0-FmF, /MTAxMzk4-FmF
2023-01-02 21:27:28 [start_ic:1706]  STAGE 4 >  iOS App Devices >
                                                                                                        ✓Lindsey's iPhone App  (lindseys_iphone_app) → lindseys_iphone_ic3 (iPhone13,2)
                                                                                                        ✓Lauren's iPhone App  (laurens_iphone_app) → laurens_iphone_ic3 (iPhone14,5)
                                                                                                        ✓Derek's iPhone App  (dereks_iphone_app) → dereks_iphone_ic3 (iPhone14,2)
                                                                                                        ✓Ryan's iPhone X  (iphone_x) → ryans_iphone_ic3 (iPhone10,6)
                                                                                                        •Kitchen iPad  (kitchen_ipad_2) → Not Monitored, Kitchen iPad (iPad (4th generation))
                                                                                                        •Lindsey’s iPad   (ipad_3) → Not Monitored, Lindsey’s iPad  (iPad13,1)
                                                                                                        •Derek's iPad App  (dereks_ipad_app) → Not Monitored, Derek's iPad App (iPad8,9)
                                                                                                        •Lauren's iPhone App  (lauren_app) → Not Monitored, Lauren's iPhone App (iPhone11,2)
2023-01-02 21:27:28 [start_ic:0248]  STAGE 4 >  Stage 4 > Setup iCloud & iOSApp Tracking Methods
2023-01-02 21:27:28 [start_ic:1908]  STAGE 5 >  ADDED StationaryZone-alans_iphone_ic3_stationary
2023-01-02 21:27:28 [start_ic:1874]  STAGE 5 >  Tracked Device > alans_iphone_ic3 (Alan's iPhone (IC3)/iPhone)
                                                                                                        •FmF Device: [email protected]
                                                                                                        •Stationary Zone: alans_iphone_ic3_stationary (Stationary)
                                                                                                        •Track from Base Zone: Opv
                                                                                                        •Track from Zones: home, opv
2023-01-02 21:27:28 [iosapp_d:0413]  STAGE 5 >  UPDATED iOSApp, lindseys_iphone_ic3, not_set, 21:27:24/±35m, (51.66154, -0.07000/±35m), 10m
2023-01-02 21:27:28 [start_ic:1908]  STAGE 5 >  ADDED StationaryZone-lindseys_iphone_ic3_stationary
2023-01-02 21:27:28 [start_ic:1874]  STAGE 5 >  Tracked Device > lindseys_iphone_ic3 (Lindsey's iPhone (IC3)/iPhone)
                                                                                                        •FamShr Device: Lindsey's iPhone
                                                                                                        •FmF Device: XXXXXXXX
                                                                                                        •iOSApp Entity: device_tracker.lindseys_iphone_app
                                                                                                        •Update Trigger: lindseys_iphone_last_update_trigger
                                                                                                        •Battery: lindseys_iphone_battery_level
                                                                                                        •Notifications: WAITING FOR NOTIFY SERVICE TO START
                                                                                                        •Stationary Zone: lindseys_iphone_ic3_stationary (Stationary)
2023-01-02 21:27:28 [iosapp_d:0413]  STAGE 5 >  UPDATED iOSApp, laurens_iphone_ic3, not_set, 21:27:24/±5m, (51.66150, -0.07007/±5m), 10m
2023-01-02 21:27:28 [start_ic:1908]  STAGE 5 >  ADDED StationaryZone-laurens_iphone_ic3_stationary
2023-01-02 21:27:28 [start_ic:1874]  STAGE 5 >  Tracked Device > laurens_iphone_ic3 (Lauren's iPhone (IC3)/iPhone)
                                                                                                        •FamShr Device: Lauren's iphone
                                                                                                        •FmF Device: XXXXXXXXXXXXXXXX
                                                                                                        •iOSApp Entity: device_tracker.laurens_iphone_app
                                                                                                        •Update Trigger: laurens_iphone_last_update_trigger
                                                                                                        •Battery: laurens_iphone_battery_level
                                                                                                        •Notifications: WAITING FOR NOTIFY SERVICE TO START
                                                                                                        •Stationary Zone: laurens_iphone_ic3_stationary (Stationary)
2023-01-02 21:27:28 [iosapp_d:0413]  STAGE 5 >  UPDATED iOSApp, dereks_iphone_ic3, not_set, 21:27:24/±7m, (51.66147, -0.07010/±7m), 0m
2023-01-02 21:27:28 [start_ic:1908]  STAGE 5 >  ADDED StationaryZone-dereks_iphone_ic3_stationary
2023-01-02 21:27:28 [start_ic:1874]  STAGE 5 >  Tracked Device > dereks_iphone_ic3 (Derek's iPhone (IC3)/iPhone)
                                                                                                        •FamShr Device: Derek's iPhone
                                                                                                        •iOSApp Entity: device_tracker.dereks_iphone_app
                                                                                                        •Update Trigger: dereks_iphone_last_update_trigger
                                                                                                        •Battery: dereks_iphone_battery_level
                                                                                                        •Notifications: WAITING FOR NOTIFY SERVICE TO START
                                                                                                        •Stationary Zone: dereks_iphone_ic3_stationary (Stationary)
2023-01-02 21:27:28 [iosapp_d:0413]  STAGE 5 >  UPDATED iOSApp, ryans_iphone_ic3, not_set, 21:27:24/±23m, (51.66143, -0.07010/±23m), 0m
2023-01-02 21:27:28 [start_ic:1908]  STAGE 5 >  ADDED StationaryZone-ryans_iphone_ic3_stationary
2023-01-02 21:27:28 [start_ic:1874]  STAGE 5 >  Tracked Device > ryans_iphone_ic3 (Ryan's iPhone (IC3)/iPhone)
                                                                                                        •FamShr Device: iPhone X
                                                                                                        •FmF Device: XXXXXXXXX
                                                                                                        •iOSApp Entity: device_tracker.iphone_x
                                                                                                        •Update Trigger: ryans_iphone_last_update_trigger
                                                                                                        •Battery: ryans_iphone_battery_level
                                                                                                        •Notifications: mobile_app_ryans_iphone
                                                                                                        •Stationary Zone: ryans_iphone_ic3_stationary (Stationary)
2023-01-02 21:27:28 [start_ic:1908]  STAGE 5 >  ADDED StationaryZone-sylvies_iphone_ic3_stationary
2023-01-02 21:27:28 [start_ic:1874]  STAGE 5 >  Tracked Device > sylvies_iphone_ic3 (Sylvie's iPhone (IC3)/iPhone)
                                                                                                        •FmF Device: [email protected]
                                                                                                        •Stationary Zone: sylvies_iphone_ic3_stationary (Stationary)
                                                                                                        •Track from Base Zone: Opv
                                                                                                        •Track from Zones: home, opv
2023-01-02 21:27:28 [start_ic:1753]  STAGE 5 >  StatZones-{'sylvies_iphone_ic3': <StatZone: sylvies_iphone_ic3_stationary>}
2023-01-02 21:27:28 [start_ic:1756]  STAGE 5 >  Devices-{'alans_iphone_ic3': <Device: alans_iphone_ic3>, 'lindseys_iphone_ic3': <Device: lindseys_iphone_ic3>, 'laurens_iphone_ic3': <Device: laurens_iphone_ic3>, 'dereks_iphone_ic3': <Device: dereks_iphone_ic3>, 'ryans_iphone_ic3': <Device: ryans_iphone_ic3>, 'sylvies_iphone_ic3': <Device: sylvies_iphone_ic3>}
2023-01-02 21:27:28 [start_ic:1761]  STAGE 5 >  Device-alans_iphone_ic3, DeviceFmZones-{'home': <DeviceFmZone: alans_iphone_ic3:home>, 'opv': <DeviceFmZone: alans_iphone_ic3:opv>}
2023-01-02 21:27:28 [start_ic:1761]  STAGE 5 >  Device-lindseys_iphone_ic3, DeviceFmZones-{'home': <DeviceFmZone: lindseys_iphone_ic3:home>}
2023-01-02 21:27:28 [start_ic:1761]  STAGE 5 >  Device-laurens_iphone_ic3, DeviceFmZones-{'home': <DeviceFmZone: laurens_iphone_ic3:home>}
2023-01-02 21:27:28 [start_ic:1761]  STAGE 5 >  Device-dereks_iphone_ic3, DeviceFmZones-{'home': <DeviceFmZone: dereks_iphone_ic3:home>}
2023-01-02 21:27:28 [start_ic:1761]  STAGE 5 >  Device-ryans_iphone_ic3, DeviceFmZones-{'home': <DeviceFmZone: ryans_iphone_ic3:home>}
2023-01-02 21:27:28 [start_ic:1761]  STAGE 5 >  Device-sylvies_iphone_ic3, DeviceFmZones-{'home': <DeviceFmZone: sylvies_iphone_ic3:home>, 'opv': <DeviceFmZone: sylvies_iphone_ic3:opv>}
2023-01-02 21:27:28 [start_ic:1764]  STAGE 5 >  Zones-{'not_home': <Zone: not_home>, 'not_set': <Zone: not_set>, 'stationary':>, 'alans_iphone_ic3_stationary': <StatZone: alans_iphone_ic3_stationary>, 'lindseys_iphone_ic3_stationary': <StatZone: lindseys_iphone_ic3_stationary>, 'laurens_iphone_ic3_stationary': <StatZone: laurens_iphone_ic3_stationary>, 'dereks_iphone_ic3_stationary': <StatZone: dereks_iphone_ic3_stationary>, 'ryans_iphone_ic3_stationary': <StatZone: ryans_iphone_ic3_stationary>, 'sylvies_iphone_ic3_stationary': <StatZone: sylvies_iphone_ic3_stationary>}
2023-01-02 21:27:28 [start_ic:0274]  STAGE 5 >  Stage 5 > Configure Tracked Devices
2023-01-02 21:27:28 [start_ic:1923]  STAGE 6 >  iCloud3 is an HA Integration. Delete the 'platform: icloud3` configuration parameters in the HA `configuration.yaml` file.
2023-01-02 21:27:28 [start_ic:1753]  STAGE 6 >  StatZones-{'sylvies_iphone_ic3': <StatZone: sylvies_iphone_ic3_stationary>}
2023-01-02 21:27:28 [start_ic:1756]  STAGE 6 >  Devices-{'alans_iphone_ic3': <Device: alans_iphone_ic3>, 'lindseys_iphone_ic3': <Device: lindseys_iphone_ic3>, 'laurens_iphone_ic3': <Device: laurens_iphone_ic3>, 'dereks_iphone_ic3': <Device: dereks_iphone_ic3>, 'ryans_iphone_ic3': <Device: ryans_iphone_ic3>, 'sylvies_iphone_ic3': <Device: sylvies_iphone_ic3>}
2023-01-02 21:27:28 [start_ic:1761]  STAGE 6 >  Device-alans_iphone_ic3, DeviceFmZones-{'home': <DeviceFmZone: alans_iphone_ic3:home>, 'opv': <DeviceFmZone: alans_iphone_ic3:opv>}
2023-01-02 21:27:28 [start_ic:1761]  STAGE 6 >  Device-lindseys_iphone_ic3, DeviceFmZones-{'home': <DeviceFmZone: lindseys_iphone_ic3:home>}
2023-01-02 21:27:28 [start_ic:1761]  STAGE 6 >  Device-laurens_iphone_ic3, DeviceFmZones-{'home': <DeviceFmZone: laurens_iphone_ic3:home>}
2023-01-02 21:27:28 [start_ic:1761]  STAGE 6 >  Device-dereks_iphone_ic3, DeviceFmZones-{'home': <DeviceFmZone: dereks_iphone_ic3:home>}
2023-01-02 21:27:28 [start_ic:1761]  STAGE 6 >  Device-ryans_iphone_ic3, DeviceFmZones-{'home': <DeviceFmZone: ryans_iphone_ic3:home>}

image

Cannot edit devices if more than 5.

In my family group we have 7 devices, some FamShr, some FMF, etc.

In the configurator, selecting icloud3 devices calls up the list of devices to edit, but you can only see the first 5 - you cannot access or edit any after that.

I've had to manually edit the configuration file to make changes to latter devices.

Sensor history not properly displayed

For some sensors (ie. battery status) history graph is showing numeric diagram instead of text value history chart.

Screenshot 2023-01-23 at 21 09 21

It should be displayed like in iOS Mobile app battery state sensor:
Screenshot 2023-01-23 at 21 09 44

I have checked the possible states, there are only text values:
Screenshot 2023-01-24 at 06 17 57

This is probably due to the fact, that there is "unit_of_measurement: " attribute added:
Screenshot 2023-01-24 at 07 08 11

Similar situation is with other sensors:

  • direction
  • info
  • ZoneName
  • etc.

Beta 8/8a - battery errors in HASS log every 5 seconds

Since 8 / 8a getting the following in the HASS log every 5 seconds

2023-01-14 23:09:30.350 ERROR (SyncWorker_17) [icloud3] invalid literal for int() with base 10: 'not_set'
Traceback (most recent call last):
  File "/config/custom_components/icloud3/device.py", line 1382, in update_iosapp_battery_information
    self.dev_data_battery_level = int(entity_io.get_state(self.iosapp_entity[BATTERY_LEVEL]))
ValueError: invalid literal for int() with base 10: 'not_set'
2023-01-14 23:09:30.351 ERROR (SyncWorker_17) [icloud3] invalid literal for int() with base 10: 'not_set'
Traceback (most recent call last):
  File "/config/custom_components/icloud3/device.py", line 1382, in update_iosapp_battery_information
    self.dev_data_battery_level = int(entity_io.get_state(self.iosapp_entity[BATTERY_LEVEL]))
ValueError: invalid literal for int() with base 10: 'not_set'
2023-01-14 23:09:30.352 ERROR (SyncWorker_17) [icloud3] invalid literal for int() with base 10: 'not_set'
Traceback (most recent call last):
  File "/config/custom_components/icloud3/device.py", line 1382, in update_iosapp_battery_information
    self.dev_data_battery_level = int(entity_io.get_state(self.iosapp_entity[BATTERY_LEVEL]))
ValueError: invalid literal for int() with base 10: 'not_set'
2023-01-14 23:09:30.353 ERROR (SyncWorker_17) [icloud3] invalid literal for int() with base 10: 'not_set'
Traceback (most recent call last):
  File "/config/custom_components/icloud3/device.py", line 1382, in update_iosapp_battery_information
    self.dev_data_battery_level = int(entity_io.get_state(self.iosapp_entity[BATTERY_LEVEL]))
ValueError: invalid literal for int() with base 10: 'not_set'

Otherwise, seems to be working ok.

In case it's relevant, I have 4 devices on FamShr (including the main device) and another 2 on FmF. Not sure if it's relevant that there seems to be 4x errors logged here every 5 seconds - perhaps one per FamShr device?

Big fix: device_tracker

Ho All,

the device_tracker shows: Home or Away instead of home or away

It's a cosmetic fix but all states are always low characters... :)

Distance Sensors in wrong Locale

Distance Sensors are appearing in Miles and not m / kM as i would expect for my HA instance configuration

All the configuration options have km as the setting, but the sensors created for devices are showing miles

image

image

Device Tracker not updating person entity with zone ?

I have the IC3 device tracker assigned to a person so that person can be located.
The zone name doesn't seem to be passing from the device tracker to the person ?

It will just show "Home" or "Unknown" instead of the zone name, it worked correctly on the released (non beta) icloud3.

Am I doing something wrong ?

2FA by hardware token - ios 16.3

Not sure if you are aware, but from ios 16.3 2FA by hardware token becomes a possibility.
This replaces the 6 digit 2FA code process.

Do you have any way of supporting this ?

Thanks

Getting Error trying to add Integration

When I click "add integration" from the Integration Configuator, I get the following error:

This device can not be added from the UI
You can add this device by adding it to your 'configuration.yaml'. See the documentation for more information.

I am doing this from a Mac, not an ios device. I got the same error when I used my iPhone as a test.

ICLOUD DEVICES

Installed everything. Integration migration seems to be working ok.

Now I try to view the "iCloud devices" to check and get a unknown error in red.

Also all sensors are empty.

10:14:16a          iCloud initializing interface
10:14:16a          iCloud3 Error > An error occurred communicating with iCloud Account servers. This can be caused by:, •You
                                        r network or wifi is down, or, •Apple iCloud servers are down, Error-(`Invalid email/password combin
10:14:16a          All Devices are offline or have a pending status. They may be in AirPlane Mode and not available
10:14:16a          Apple ID Verification - Completed

Then I did a manual re-enter username and password. Give the 2way authcode and now this is de log:

10:21:56a          AUTHENTICATE PyiCloud, [email protected], config_flow
10:21:57a          ADDED FamShr PyiCloudDevice-, Apple Watch van Peter/QkKnPAD4aj
10:21:57a          NO LOCATION FamShr PyiCloudData-Peter’s MacBook Pro
10:21:57a          ADDED FamShr PyiCloudDevice-, iMac van Peter/2DdaH7FTtm
10:21:57a          ADDED FamShr PyiCloudDevice-, Peter iPhone/5yAbrrC4uE
10:21:57a          NO LOCATION FamShr PyiCloudData-cenkay’s iPhone
10:21:57a          NO LOCATION FamShr PyiCloudData-cenkay’s iPhone
10:21:57a          NO LOCATION FamShr PyiCloudData-iPhone
10:21:57a          ADDED FamShr PyiCloudDevice-, Cenkay 13/nA/v6NXyDu
10:21:57a          ADDED FamShr PyiCloudDevice-, AirPods van Cenkay/nKz8eqmhd1
10:21:57a          CREATED PyiCloud FamShr, [email protected], config_flow
10:21:59a          CREATED PyiCloud FmF, [email protected], config_flow
10:22:14a          Alert > Apple ID Verification completed successfully (366347)
10:22:14a          Cancel previous alerts

Still all sensors not updated. Battery has a !
Will it change when I will move from home so there will be data coming in?

Also the ICLOUD DEVICES Gives me same error "unknown error in red."

One device location not updating (Beta 8a)

I have a phone who's location isn't updating in IC3. It's setup as a FamShr device and in the FindMy app the location is displaying just fine. It seems to be just this one device - I have other FamShr devices in my account that are updating just fine.

icloud3 says:

image

and, even after restarting and forcing a location refresh:

image

(As an aside, I notice the log says CountryCode-US, even though I've set Waze to be RoW and my HASS setup is set for UK/GB).

Several errors in HA log

Hey,

I remove always old files and unzip the new once. With icloud3-beta4 I get this error message:
Checked configuration and restart iCloud3. Also restarted HA again get same errors.

2022-12-28 08:59:15.927 ERROR (SyncWorker_2) [icloud3] name 'log_info_msg' is not defined
Traceback (most recent call last):
  File "/config/custom_components/icloud3/support/iosapp_interface.py", line 128, in get_mobile_app_notifications
    notify_services = dict(services.__dict__)['_services']['notify']
KeyError: 'notify'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/config/custom_components/icloud3/support/iosapp_interface.py", line 103, in get_entity_registry_mobile_app_devices
    notify_iosapp_devicenames = get_mobile_app_notifications()
  File "/config/custom_components/icloud3/support/iosapp_interface.py", line 135, in get_mobile_app_notifications
    log_info_msg("iOS App Notify Service has not been set up yet. iCloud3 will retry later.")
NameError: name 'log_info_msg' is not defined
2022-12-28 08:59:15.936 ERROR (SyncWorker_2) [icloud3] name 'log_info_msg' is not defined
Traceback (most recent call last):
  File "/config/custom_components/icloud3/support/iosapp_interface.py", line 128, in get_mobile_app_notifications
    notify_services = dict(services.__dict__)['_services']['notify']
KeyError: 'notify'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/config/custom_components/icloud3/support/start_ic3_control.py", line 225, in stage_4_setup_tracking_methods
    start_ic3.setup_tracked_devices_for_iosapp()
  File "/config/custom_components/icloud3/support/start_ic3.py", line 1690, in setup_tracked_devices_for_iosapp
    setup_notify_service_name_for_iosapp_devices()
  File "/config/custom_components/icloud3/support/start_ic3.py", line 1721, in setup_notify_service_name_for_iosapp_devices
    notify_iosapp_devicenames = iosapp_interface.get_mobile_app_notifications()
  File "/config/custom_components/icloud3/support/iosapp_interface.py", line 135, in get_mobile_app_notifications
    log_info_msg("iOS App Notify Service has not been set up yet. iCloud3 will retry later.")
NameError: name 'log_info_msg' is not defined
2022-12-28 08:59:16.010 ERROR (SyncWorker_2) [icloud3] name 'log_info_msg' is not defined
Traceback (most recent call last):
  File "/config/custom_components/icloud3/support/iosapp_interface.py", line 128, in get_mobile_app_notifications
    notify_services = dict(services.__dict__)['_services']['notify']
KeyError: 'notify'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/config/custom_components/icloud3/support/iosapp_interface.py", line 103, in get_entity_registry_mobile_app_devices
    notify_iosapp_devicenames = get_mobile_app_notifications()
  File "/config/custom_components/icloud3/support/iosapp_interface.py", line 135, in get_mobile_app_notifications
    log_info_msg("iOS App Notify Service has not been set up yet. iCloud3 will retry later.")
NameError: name 'log_info_msg' is not defined
2022-12-28 08:59:16.018 ERROR (SyncWorker_2) [icloud3] name 'log_info_msg' is not defined
Traceback (most recent call last):
  File "/config/custom_components/icloud3/support/iosapp_interface.py", line 128, in get_mobile_app_notifications
    notify_services = dict(services.__dict__)['_services']['notify']
KeyError: 'notify'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/config/custom_components/icloud3/support/start_ic3_control.py", line 225, in stage_4_setup_tracking_methods
    start_ic3.setup_tracked_devices_for_iosapp()
  File "/config/custom_components/icloud3/support/start_ic3.py", line 1690, in setup_tracked_devices_for_iosapp
    setup_notify_service_name_for_iosapp_devices()
  File "/config/custom_components/icloud3/support/start_ic3.py", line 1721, in setup_notify_service_name_for_iosapp_devices
    notify_iosapp_devicenames = iosapp_interface.get_mobile_app_notifications()
  File "/config/custom_components/icloud3/support/iosapp_interface.py", line 135, in get_mobile_app_notifications
    log_info_msg("iOS App Notify Service has not been set up yet. iCloud3 will retry later.")
NameError: name 'log_info_msg' is not defined

Conflict between phone and watch location

I went for a run tonight with my Apple Watch (with e-sim) and left my phone at home.
I have the watch ic3 and iPhone ic3 device trackers set up and linked to my person.bruce
As each device checked in it would toggle me from home / away / home / away etc.

Any thoughts on the best way to handle this.
ideally ic3 would know that my watch was moving and my phone wasn’t. So wouldn’t update the tracker on my phone.
Particularly if my phone was on charge.

Thinking out loud.
I guess I could add an automation that when my phone goes on charge it disables updates on iCloud3 location until it comes off charge ?
Is that possible ?

Anyone have thoughts on how this should best be handled ?

thanks.

@marceloaf Migration v2.4.7 to v3 startup problems

    @marceloaf  Go ahead and send them. The items i fixed probably would not have anything to do with your issues.

Also lets open an new issue on your startup problems. I'm trying to keep this issue related to new releases, change logs and people using the beta release, not problems. Thanks

Originally posted by @gcobb321 in #2 (comment)

type object 'GlobalVariables' has no attribute 'iC3_debug_log_file_last_write_secs'

Heym

With latest beta release I see this error every 5 minutes:

2022-12-25 12:05:00.292 ERROR (MainThread) [homeassistant] Error doing job: Future exception was never retrieved
Traceback (most recent call last):
  File "/usr/local/lib/python3.10/concurrent/futures/thread.py", line 58, in run
    result = self.fn(*self.args, **self.kwargs)
  File "/config/custom_components/icloud3/icloud3_main.py", line 209, in _polling_loop_5_sec_device
    self._main_5sec_loop_special_time_control()
  File "/config/custom_components/icloud3/icloud3_main.py", line 479, in _main_5sec_loop_special_time_control
    if (Gb.iC3_debug_log_file_last_write_secs > 0
AttributeError: type object 'GlobalVariables' has no attribute 'iC3_debug_log_file_last_write_secs'

"Reset iCloud3 Interface" Not Functioning

I'm having an authentication issue with icloud3 v2.4.7 such that it tells me in the logs:

"iCloud3 Error > iCloud Account Authentication needed > Will use iOS App Tracking Method until the iCloud account is authentication is complete. See the HA Notification area to continue. iCloud3 will then be restarted."

The HA notification area remains empty even after waiting 10 minutes after clicking 'Reset iCloud3 Interface' on the iCloud3 event log card.

This integration worked until about a week or so ago for me. I'm guessing that was when this particular authentication session ended, since they expire every 30 days or so. Is there a "correct" process to force this that doesn't include the "Reset iCloud3 Interface" button?

Feature Request - Delete Credentials when removing integration

For Cutover to release 8b I deleted the integration in HA, deleted the folder, replaced the folder and rebooted.

To my surprise when i went to reconfigure iCloud3 it had my credentials cached already.

This is bad security practice and unused credentials should not be left in the HA database after removal of the integration.

Can we please add this as a unload step

Country Code issue in beta 8a / 8b

I don't think I can see a solution above.... Is there a forum I should be posting in for questions. Just installed the beta. It seems to be having problems with my country code..

It is set on config.yaml

homeassistant:
  country: GB

2023-01-16 19:29:10.185 ERROR (MainThread) [homeassistant.setup] Error during setup of component icloud3
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/setup.py", line 253, in _async_setup_component
    result = await task
  File "/config/custom_components/icloud3/__init__.py", line 74, in async_setup
    v2v3_config_migration.convert_v2_config_files_to_v3()
  File "/config/custom_components/icloud3/support/v2v3_config_migration.py", line 179, in convert_v2_config_files_to_v3
    self._set_data_fields_from_config_parameter_dictionary()
  File "/config/custom_components/icloud3/support/v2v3_config_migration.py", line 570, in _set_data_fields_from_config_parameter_dictionary
    Gb.conf_general[CONF_WAZE_REGION]                = WAZE_SERVERS_BY_COUNTRY_CODE.get(Gb.ha_country_code, 'row')
AttributeError: type object 'GlobalVariables' has no attribute 'ha_country_code'

Please advise.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.