home-assistant / home-assistant/iOS
Notifications on Apple Watch no longer uses pre-downloaded attached picture
- Dominant language
- Swift
- Stars
- 2.4k
- Forks
- 520
- Avg merge
- 7h 27m
- Merged PRs (30d)
- 264
Description
**iOS device model, version and app version**
Model Name: iPhone 12 Pro / Apple Watch Series 4
Software Version: 14.5.1 / 7.4.1
App version: 2021.150
**Home Assistant Core Version**
2021.5.1
**Describe the bug**
Push notifications with an attached image (URL is https://blueiris.apps.blah/...) work correctly on the iPhone, however on my Apple Watch they show the error "Failed to load attachment URLSessionTask failed with error: The certificate for this server is invalid. You might be connecting to a server that is pretending to be "blueiris.apps.blah" which could put your confidential information at risk."
**To Reproduce**
Send a notification to the Home Assistant companion app as follows (this is built in a Node-RED flow, but is ultimately passed to a call to the notify service in Home Assistant):
```
"data": {
"data": {
"url": "https://blueiris.apps.blah/ui3.htm?rec=479830131-2618414",
"attachment": {
"url": "https://blueiris.apps.blah/alerts/@480260921.jpg"
}
},
"title": "Front Door",
"message": "Motion Detected (Car, Transportation, Vehicle, Automobile, Porch, Patio, Chair, Furniture, Wheel, Machine)"
}
```
The notification on the iPhone shows the picture referenced in the attachment URL. The notification on the Apple Watch shows the URLSessionTask error referenced above.
**Expected behavior**
The notification on the iPhone will show the picture referenced in the attachment URL. The notification on the Apple Watch will also show the picture referenced in the attachment URL.
**Additional context**
The Root CA certificate is installed on my iPhone via a configuration profile. There are no extra profiles or CA certificates installed on the Apple Watch.
This error started when I updated the Home Assistant companion app today. The previous version of the app showed the notification correctly on the Apple Watch.
There are no certificate warnings reported in Safari, nor are there any errors shown in the Home Assistant companion app.
Contributor guide
Assessment
This issue has not been assessed yet.