android: Mobile app notification does not work
Home Assistant Android version: 1.8.0-144 Android version: 10 Phone model: Galaxy S10+ Home Assistant version: 0.107.4 Last working Home Assistant release (if known):
Description of problem:
When trying to send a notification to mobile app using the notify.mobile_app_** service from the developer tools I get the below error.
Traceback (if applicable):
hass | 2020-03-21 22:37:32 ERROR (MainThread) [homeassistant.components.websocket_api.http.connection.2961320208] 0, message='Attempt to decode JSON with unexpected mimetype: text/html; charset=utf-8', url='https://mobile-apps.home-assistant.io/api/sendPush/android/v1
hass | Traceback (most recent call last):
hass | File "/usr/src/homeassistant/homeassistant/components/websocket_api/commands.py", line 134, in handle_call_service
hass | connection.context(msg),
hass | File "/usr/src/homeassistant/homeassistant/core.py", line 1234, in async_call
hass | await asyncio.shield(self._execute_service(handler, service_call))
hass | File "/usr/src/homeassistant/homeassistant/core.py", line 1257, in _execute_service
hass | await handler.func(service_call)
hass | File "/usr/src/homeassistant/homeassistant/components/notify/__init__.py", line 119, in async_notify_message
hass | await notify_service.async_send_message(**kwargs)
hass | File "/usr/src/homeassistant/homeassistant/components/mobile_app/notify.py", line 135, in async_send_message
hass | result = await response.json()
hass | File "/usr/local/lib/python3.7/site-packages/aiohttp/client_reqrep.py", line 1031, in json
hass | headers=self.headers)
Screenshot of problem:

Additional information:
About this issue
- Original URL
- State: closed
- Created 4 years ago
- Comments: 18 (6 by maintainers)
Or use HTTP proxy.
I set up Privoxy so that it only forwards some URLs to another upstreadm proxy:
But to make Hass use the HTTP proxy, I had to set
HTTP_PROXYenv var and also manually modify/usr/src/homeassistant/homeassistant/helpers/aiohttp_client.pyto make it respect and use this env var as said here.use persistent connection for notifications
https://companion.home-assistant.io/docs/notifications/notification-local