What I am proposing is to edit the behavior of the onboarding of a new mobile app integration. Currently if a person with associated user logs into the app and that app has never been connected to that user or HA instance before (therefore no token for that user_id or device exists), it assigns the device tracker to that person without prompting or even so much as a notice of “hey we did this thing”. So on the edit person screen you see all device trackers associated with said person. The JSON of the person file in the .storage folder shows this:
{
"version": 2,
"minor_version": 1,
"key": "person",
"data": {
"items": [
{
"device_trackers": [
"device_tracker.b_iphone"
],
"id": "d82f########################46a6",
"name": "B",
"user_id": "d86b########################5943",
"picture": "/api/image/serve/feae9048########################/512x512"
},
...
what would be nice is on initial onboarding which configures the mobile app integration, it asks “Should this device be used for Person X tracking?”. A check box, a toggle, or a “yes” or “no” and it places the device tracker entity under either an include or exclude heading under the device trackers for the person. Kind of how the include or exclude of the recorder is formatted. then every time the frontend of the app refreshes or this “login” occurs, the backend can check if the device tracker exists under the person (regardless if it is included or excluded) and if it does, don’t change anything because it’s already been decided. If this isn’t the right place, then maybe a new heading in the mobile_app file under the .storage folder.
What this feature request does is prevent device trackers that are created for devices you login to using the mobile app, but do not physically move, from being used to determine the person’s location and home/away state. Example is a macOS laptop and an iPhone. One or the other may be used for tracking, but maybe the laptop shouldn’t be. But maybe you use the device tracker entity of the laptop in some automations like for lights. So you need the device tracker, but don’t want it to be tied to the person who logged into the app. Right now, periodically the mobile app will re-associate the device tracker to the person without notice. Then you have to go into the person editor and manually remove it.