Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

"notify.mobile_app" Not Handling Duplicate Device Correctly (devices with the same names) #117716

Open
lucddm opened this issue May 19, 2024 · 3 comments

Comments

@lucddm
Copy link

lucddm commented May 19, 2024

The problem

I was trying to set up notifications / create a custom script (using the "mobile_app_" component for notifications) for multiple mobile devices. Two or more devices had the same name, for example, "SM-A365F". When attempting to send notifications using "notify.mobile_app_<device_name>", only one service was listed in the available services "notify.mobile_app_sm-a365".

After verification, Home Assistant successfully handles device trackers as follows:

  • Device 1: "device_tracker.sm_a325f"
  • Device 2: "device_tracker.sm_a325f_2"

However, for notifications, only notify.mobile_app_sm_a325f was available. When using this notification service, only one device receives the notification.

Additionally, if I try to use the following Home Assistant script (generated by H.A) that should send a notification to one of the 2 devices, I get this error: "Error: Unable to find notify service for webhook ID".

alias: New Script
sequence:
    device_id: 84678f6435h85av693dj72eb78k67e23
    domain: mobile_app
    type: notify
    message: Test

What version of Home Assistant Core has the issue?

core-2024.5.3

What was the last working version of Home Assistant Core?

No response

What type of installation are you running?

Home Assistant Container

Integration causing the issue

mobile_app

Link to integration documentation on our website

https://www.home-assistant.io/integrations/mobile_app/

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

@home-assistant
Copy link

Hey there @home-assistant/core, mind taking a look at this issue as it has been labeled with an integration (mobile_app) you are listed as a code owner for? Thanks!

Code owner commands

Code owners of mobile_app can trigger bot actions by commenting:

  • @home-assistant close Closes the issue.
  • @home-assistant rename Awesome new title Renames the issue.
  • @home-assistant reopen Reopen the issue.
  • @home-assistant unassign mobile_app Removes the current integration label and assignees on the issue, add the integration domain after the command.
  • @home-assistant add-label needs-more-information Add a label (needs-more-information, problem in dependency, problem in custom component) to the issue.
  • @home-assistant remove-label needs-more-information Remove a label (needs-more-information, problem in dependency, problem in custom component) on the issue.

(message by CodeOwnersMention)


mobile_app documentation
mobile_app source
(message by IssueLinks)

@McNobby
Copy link

McNobby commented May 19, 2024

Just set up my HA instance today (Running in proxmox VM), and im having the same problem. Im not very proficient in home assistant yet, so i don't know how to see the two phones ids.

This image shows the one phone in the automation visual editor.
bilde

Both phones are pixel 7 pro and it looks like the last phone to be logged in is the one actually recieveing the notifications.

In the mobile app integration i can see this, both with the same name, probably because it is the same model.
bilde

And here in the devices page both phones are showing with their respective names
bilde

Hope this helps

EDIT: im also unable to send message to the first registered phone through a script
bilde

device_id: [...]
domain: mobile_app
type: notify
message: HEllo world
title: Test notif

@McNobby
Copy link

McNobby commented May 20, 2024

Updated: seems to work now, cant recall updating or changing much. But got seperate options for each phone

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants