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

Phone Notification Local Image fails to download #3926

Closed
milandzuris opened this issue Oct 8, 2023 · 11 comments · Fixed by #3930
Closed

Phone Notification Local Image fails to download #3926

milandzuris opened this issue Oct 8, 2023 · 11 comments · Fixed by #3930
Labels
bug Something isn't working notifications

Comments

@milandzuris
Copy link

milandzuris commented Oct 8, 2023

Hi i have Samsuing and Android 13, last few months idk why but Local image notifcations not work i dont see in phone, logs are clear in phone everytinhg is good, but when i will replace it with a url everything is works good, where is the problem?, thx,

service: notify.mobile_app_milan_phone
data:
  message: test
  data:
    image: /media/local/Camera Snapshots/Doorbell Camera.jpg

image

@milandzuris milandzuris added the bug Something isn't working label Oct 8, 2023
@dshokouhi
Copy link
Member

Please do not delete the issue template that gets presented when you create a issue, all information is important to help you out.

@dshokouhi dshokouhi added question Further information is requested notifications labels Oct 9, 2023
@milandzuris
Copy link
Author

Please do not delete the issue template

???

@milandzuris
Copy link
Author

@dshokouhi
Copy link
Member

Please do not delete the issue template

???

the issue template gets presented when you create a new issue (like when the bug label appears) it contains important information like app version, HA core version etc.. that we need so we have all necessary data

@dshokouhi
Copy link
Member

So looking at the logs I don't see a failure in the image retrieval so I am not sure whats going on here

10-10 21:32:22.495 14287 29072 D FCMService: From: 331041709873
10-10 21:32:22.498 14287 14287 D MessagingService: Creating notification with following data: {image=/media/local/Camera Snapshots/Doorbell Camera.jpg, webhook_id=6e04a39348249ac3ec4aa240118f19274c762adaf536a44dc83d52f147f68ffd, message=test, server_id=4}
10-10 21:32:22.520 14287 14287 D ServerConnectionInfo: localUrl is: true, usesInternalSsid is: true, usesWifi is: true
10-10 21:32:22.520 14287 14287 D ServerConnectionInfo: Using internal URL
10-10 21:32:22.524 14287 14287 W UrlUtil : Invalid input, returning base only
10-10 21:32:22.553 14287 14317 D ServerConnectionInfo: localUrl is: true, usesInternalSsid is: true, usesWifi is: true
10-10 21:32:22.553 14287 14317 D ServerConnectionInfo: Using internal URL
10-10 21:32:22.560 14287 14317 D TrafficStats: tagSocket(6) with statsTag=0xf
10-10 21:32:22.614 14287 14317 D OpenGLRenderer: --- result 'unimplemented'
10-10 21:32:22.620 14287 14287 D MessagingService: Show notification with tag "null" and id "454260575"

are there any HA core logs that may help give a clue?

@milandzuris
Copy link
Author

So looking at the logs I don't see a failure in the image retrieval so I am not sure whats going on here

10-10 21:32:22.495 14287 29072 D FCMService: From: 331041709873
10-10 21:32:22.498 14287 14287 D MessagingService: Creating notification with following data: {image=/media/local/Camera Snapshots/Doorbell Camera.jpg, webhook_id=6e04a39348249ac3ec4aa240118f19274c762adaf536a44dc83d52f147f68ffd, message=test, server_id=4}
10-10 21:32:22.520 14287 14287 D ServerConnectionInfo: localUrl is: true, usesInternalSsid is: true, usesWifi is: true
10-10 21:32:22.520 14287 14287 D ServerConnectionInfo: Using internal URL
10-10 21:32:22.524 14287 14287 W UrlUtil : Invalid input, returning base only
10-10 21:32:22.553 14287 14317 D ServerConnectionInfo: localUrl is: true, usesInternalSsid is: true, usesWifi is: true
10-10 21:32:22.553 14287 14317 D ServerConnectionInfo: Using internal URL
10-10 21:32:22.560 14287 14317 D TrafficStats: tagSocket(6) with statsTag=0xf
10-10 21:32:22.614 14287 14317 D OpenGLRenderer: --- result 'unimplemented'
10-10 21:32:22.620 14287 14287 D MessagingService: Show notification with tag "null" and id "454260575"

are there any HA core logs that may help give a clue?

HA Logs are Empty, I'm already frustrated, but extremely already :(

@milandzuris
Copy link
Author

I do not understand why have problem only with local image

@jpelgrom
Copy link
Member

It looks like URL validation fails because your URL includes spaces, which are not a valid character. I'll submit a change to handle this in the app as it is quite a common pattern and is valid in YAML. For now, you can manually url encode the spaces (%20) and it should work.

@jpelgrom jpelgrom changed the title Phone Notification Local Image Phone Notification Local Image fails to download Oct 11, 2023
@jpelgrom jpelgrom removed the question Further information is requested label Oct 11, 2023
@milandzuris
Copy link
Author

milandzuris commented Oct 11, 2023

It looks like URL validation fails because your URL includes spaces

sorry, What URL do u mean?

@jpelgrom
Copy link
Member

/media/local/Camera Snapshots/Doorbell Camera.jpg should be /media/local/Camera%20Snapshots/Doorbell%20Camera.jpg. If you use the media browser in a browser and right click > open image in new tab, you can see what I mean.

@milandzuris
Copy link
Author

/media/local/Camera Snapshots/Doorbell Camera.jpg should be /media/local/Camera%20Snapshots/Doorbell%20Camera.jpg. If you use the media browser in a browser and right click > open image in new tab, you can see what I mean.

Working, really thank you so much after few months fixed, thx

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working notifications
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants