iOS notifications and component not configured after restore

I did a full restore from a snapshot to a new SD card and all seemed to go well apart from the following notification.

Screen2018-11-24_09-45-05_am

Clearly, something wasn’t added to the snapshot, and consequently not restored.

Where do I need to start looking for this?

I have updated to the current version of HassIO as part of the restore but the breaking changes don’t indicate that the iOS component should be an issue.

Did you use discovery to set up your ios device?

If so have a look in configuration/integrations and configure your phone again.

Thanks, for your help, Tom.

It was automatically configured, so that’s not the problem.

Screen2018-11-24_12-26-09_pm

Any other suggestions?

It’s all working fine on the instance that I created the snapshot from.

The only changes are updated Mosquitto MQTT and HASSIO 0.82.1.

When I look at the loaded components, iOS isn’t showing up.

Other than wiping the integration and re-adding it I’ve got nothing.

Did you update push settings in the app? I doubt this will help as it seems to be a problem on the HA side of things, but worth a try I guess.

Yes, I tried that already.

Interestingly, it’s loading the iOS device tracker fine.

What’s it saying in your logs? There isn’t much to the ios config other than ios:.

Here are the log entries that relate to iOS.

2018-11-24 13:02:36 ERROR (SyncWorker_16) [homeassistant.util.json] Could not parse JSON content: /config/.ios.conf

2018-11-24 13:02:36 ERROR (MainThread) [homeassistant.setup] Error during setup of component ios

File “/usr/local/lib/python3.6/site-packages/homeassistant/components/ios/init.py”, line 203, in async_setup

2018-11-24 13:02:36 ERROR (MainThread) [homeassistant.setup] Unable to set up dependencies of notify.ios. Setup failed for dependencies: ios

2018-11-24 13:02:36 ERROR (MainThread) [homeassistant.setup] Unable to prepare setup for platform notify.ios: Could not set up all dependencies.

2018-11-24 13:02:42 WARNING (MainThread) [homeassistant.core] Unable to find service notify/ios_ash_x

Need the full logs in the homeassistant.log file, not what’s shown on the UI.

Also, when replying, use the reply button on the persons post instead of the one on the thread. That will notify the user of a response. Otherwise they will not know you responded and they’ll have to actively return to the thread.

Here’s the full log.

I just picked out the relevant lines before for brevity:

2018-11-24 13:02:29 WARNING (Recorder) [homeassistant.components.recorder] Ended unfinished session (id=90 from 2018-11-24 12:52:00.552347)
2018-11-24 13:02:30 WARNING (MainThread) [homeassistant.loader] You are using a custom component for device_tracker.life360 which has not been tested by Home Assistant. This component might cause stability problems, be sure to disable it if you do experience issues with Home Assistant.
2018-11-24 13:02:35 WARNING (MainThread) [homeassistant.components.cover.mqtt] Payload is not True or False: stop
2018-11-24 13:02:36 ERROR (SyncWorker_16) [homeassistant.util.json] Could not parse JSON content: /config/.ios.conf
Traceback (most recent call last):
File “/usr/local/lib/python3.6/site-packages/homeassistant/util/json.py”, line 30, in load_json
return json.loads(fdesc.read()) # type: ignore
File “/usr/local/lib/python3.6/json/init.py”, line 354, in loads
return _default_decoder.decode(s)
File “/usr/local/lib/python3.6/json/decoder.py”, line 339, in decode
obj, end = self.raw_decode(s, idx=_w(s, 0).end())
File “/usr/local/lib/python3.6/json/decoder.py”, line 357, in raw_decode
raise JSONDecodeError(“Expecting value”, s, err.value) from None
json.decoder.JSONDecodeError: Expecting value: line 1 column 1 (char 0)
2018-11-24 13:02:36 ERROR (MainThread) [homeassistant.setup] Error during setup of component ios
Traceback (most recent call last):
File “/usr/local/lib/python3.6/site-packages/homeassistant/util/json.py”, line 30, in load_json
return json.loads(fdesc.read()) # type: ignore
File “/usr/local/lib/python3.6/json/init.py”, line 354, in loads
return _default_decoder.decode(s)
File “/usr/local/lib/python3.6/json/decoder.py”, line 339, in decode
obj, end = self.raw_decode(s, idx=_w(s, 0).end())
File “/usr/local/lib/python3.6/json/decoder.py”, line 357, in raw_decode
raise JSONDecodeError(“Expecting value”, s, err.value) from None
json.decoder.JSONDecodeError: Expecting value: line 1 column 1 (char 0)

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File “/usr/local/lib/python3.6/site-packages/homeassistant/setup.py”, line 145, in _async_setup_component
hass, processed_config)
File “/usr/local/lib/python3.6/site-packages/homeassistant/components/ios/init.py”, line 203, in async_setup
load_json, hass.config.path(CONFIGURATION_FILE))
File “/usr/local/lib/python3.6/concurrent/futures/thread.py”, line 56, in run
result = self.fn(*self.args, **self.kwargs)
File “/usr/local/lib/python3.6/site-packages/homeassistant/util/json.py”, line 36, in load_json
raise HomeAssistantError(error)
homeassistant.exceptions.HomeAssistantError: Expecting value: line 1 column 1 (char 0)
2018-11-24 13:02:36 ERROR (MainThread) [homeassistant.setup] Unable to set up dependencies of notify.ios. Setup failed for dependencies: ios
2018-11-24 13:02:36 ERROR (MainThread) [homeassistant.setup] Unable to prepare setup for platform notify.ios: Could not set up all dependencies.
2018-11-24 13:02:36 ERROR (MainThread) [homeassistant.components.notify] Unknown notification service specified
2018-11-24 13:02:37 ERROR (Recorder) [homeassistant.components.recorder.util] Error executing query: (sqlite3.DatabaseError) database disk image is malformed [SQL: ‘INSERT INTO events (event_type, event_data, origin, time_fired, created, context_id, context_user_id) VALUES (?, ?, ?, ?, ?, ?, ?)’] [parameters: (‘service_registered’, ‘{“domain”: “recorder”, “service”: “purge”}’, ‘LOCAL’, ‘2018-11-24 13:02:26.081301’, ‘2018-11-24 13:02:37.502186’, ‘xxxxxxxxxxx’, None)] (Background on this error at: http://sqlalche.me/e/4xp6)
2018-11-24 13:02:42 WARNING (MainThread) [homeassistant.core] Unable to find service notify/ios_ash_x
2018-11-24 13:04:03 WARNING (MainThread) [homeassistant.components.http.auth] You need to use a bearer token to access /api/config from 10.0.1.38
2018-11-24 13:04:04 WARNING (MainThread) [homeassistant.components.http.ban] Login attempt or request with invalid authentication from 10.0.1.38
2018-11-24 13:04:04 WARNING (MainThread) [homeassistant.components.http.ban] Login attempt or request with invalid authentication from 10.0.1.38

Ok, make a backup of .ios.conf in your homeassistant config directory. Call it anything. Once backed up delete .ios.conf and restart the system.

It’ll be like starting over on your phone. You may need to delete the app and reinstall it and re log in. Or you may need to just update the push settings. Either way that file is causing your problems. It’s malformed currently and the component will always error until that is fixed. Because you and I do not know the correct format, it’s best to just delete the file and have home assistant make it as people log in with the app.

1 Like

Thank you.

I’ve done that but it’s not recreating the ios.conf file.

I deleted the iOS integration and re added it. It’s showing “this integration has no devices”. However, the app still communicates with HassIO.

Stumped!

Yeah but have you updated your push settings?

Sorry, yes, I have done that too. Several times.

:man_shrugging: No clue then! That integration has caused me problems. It’s possible that the push is broken because I tried to use it the other day and it didn’t work. I had to manually place the push_id into the .ios.config file.

You need to have the app open at the settings page for it to be recognised. Either at restart or wait about 5 minutes.

1 Like

The log now shows:

2018-11-24 13:56:14 WARNING (Recorder) [homeassistant.components.recorder] Ended unfinished session (id=92 from 2018-11-24 13:49:37.864844)
2018-11-24 13:56:17 WARNING (MainThread) [homeassistant.loader] You are using a custom component for device_tracker.life360 which has not been tested by Home Assistant. This component might cause stability problems, be sure to disable it if you do experience issues with Home Assistant.
2018-11-24 13:56:26 WARNING (MainThread) [homeassistant.components.cover.mqtt] Payload is not True or False: stop
2018-11-24 13:56:27 ERROR (SyncWorker_5) [homeassistant.util.json] Could not parse JSON content: /config/.ios.conf
Traceback (most recent call last):
File “/usr/local/lib/python3.6/site-packages/homeassistant/util/json.py”, line 30, in load_json
return json.loads(fdesc.read()) # type: ignore
File “/usr/local/lib/python3.6/json/init.py”, line 354, in loads
return _default_decoder.decode(s)
File “/usr/local/lib/python3.6/json/decoder.py”, line 339, in decode
obj, end = self.raw_decode(s, idx=_w(s, 0).end())
File “/usr/local/lib/python3.6/json/decoder.py”, line 357, in raw_decode
raise JSONDecodeError(“Expecting value”, s, err.value) from None
json.decoder.JSONDecodeError: Expecting value: line 1 column 1 (char 0)
2018-11-24 13:56:27 ERROR (MainThread) [homeassistant.setup] Error during setup of component ios
Traceback (most recent call last):
File “/usr/local/lib/python3.6/site-packages/homeassistant/util/json.py”, line 30, in load_json
return json.loads(fdesc.read()) # type: ignore
File “/usr/local/lib/python3.6/json/init.py”, line 354, in loads
return _default_decoder.decode(s)
File “/usr/local/lib/python3.6/json/decoder.py”, line 339, in decode
obj, end = self.raw_decode(s, idx=_w(s, 0).end())
File “/usr/local/lib/python3.6/json/decoder.py”, line 357, in raw_decode
raise JSONDecodeError(“Expecting value”, s, err.value) from None
json.decoder.JSONDecodeError: Expecting value: line 1 column 1 (char 0)

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File “/usr/local/lib/python3.6/site-packages/homeassistant/setup.py”, line 145, in _async_setup_component
hass, processed_config)
File “/usr/local/lib/python3.6/site-packages/homeassistant/components/ios/init.py”, line 203, in async_setup
load_json, hass.config.path(CONFIGURATION_FILE))
File “/usr/local/lib/python3.6/concurrent/futures/thread.py”, line 56, in run
result = self.fn(*self.args, **self.kwargs)
File “/usr/local/lib/python3.6/site-packages/homeassistant/util/json.py”, line 36, in load_json
raise HomeAssistantError(error)
homeassistant.exceptions.HomeAssistantError: Expecting value: line 1 column 1 (char 0)
2018-11-24 13:56:27 ERROR (MainThread) [homeassistant.setup] Unable to set up dependencies of notify.ios. Setup failed for dependencies: ios
2018-11-24 13:56:27 ERROR (MainThread) [homeassistant.setup] Unable to prepare setup for platform notify.ios: Could not set up all dependencies.
2018-11-24 13:56:27 ERROR (MainThread) [homeassistant.components.notify] Unknown notification service specified
2018-11-24 13:56:28 ERROR (Recorder) [homeassistant.components.recorder.util] Error executing query: (sqlite3.DatabaseError) database disk image is malformed [SQL: ‘INSERT INTO events (event_type, event_data, origin, time_fired, created, context_id, context_user_id) VALUES (?, ?, ?, ?, ?, ?, ?)’] [parameters: (‘service_registered’, ‘{“domain”: “recorder”, “service”: “purge”}’, ‘LOCAL’, ‘2018-11-24 13:56:13.088364’, ‘2018-11-24 13:56:28.858349’, ‘xxxxxxx’, None)] (Background on this error at: http://sqlalche.me/e/4xp6)
2018-11-24 13:56:29 WARNING (MainThread) [homeassistant.core] Unable to find service notify/ios_ash_x
2018-11-24 14:11:50 WARNING (MainThread) [homeassistant.components.binary_sensor.mqtt] No matching payload found for entity: Garage Motion with state_topic: tele/Garage_RF_Bridge/RESULT
2018-11-24 14:11:53 WARNING (MainThread) [homeassistant.components.binary_sensor.mqtt] No matching payload found for entity: Garage Motion with state_topic: tele/Garage_RF_Bridge/RESULT
2018-11-24 14:11:53 WARNING (MainThread) [homeassistant.core] Unable to find service notify/iphone
2018-11-24 14:11:53 WARNING (MainThread) [homeassistant.components.binary_sensor.mqtt] No matching payload found for entity: Garage Motion with state_topic: tele/Garage_RF_Bridge/RESULT
2018-11-24 14:11:53 WARNING (MainThread) [homeassistant.core] Unable to find service notify/iphone
2018-11-24 14:11:55 WARNING (MainThread) [homeassistant.core] Unable to find service notify/ios_ash_x

Thats the same error

See this section for discovery.

You have just installed the app and are at the getting started screen.

Automated discovery and component loading only happens at first install of the app. You may need to wait a few minutes for the iOS component to load as the discovery component only scans the network every 5 minutes.

Ah, seems like he should delete the component and install the app again. Explains why i’ve always had to install the app again when I switch hardware.

Yes, I tried both of those. Still no joy.