Home assistant supervisor fails after attempt to install DuckDNS and LetsEncrypt addons

Hi,

I’ve unfortunately run into a problem after attempting to install the DuckDNS and LetsEncrypt addons. I’m not entirely sure what my mistake was, but it looks like the configuration.yml may be in a strange state. When I check the configuration via the button in settings I am told everything is alright, however at startup I see errors and I then cannot access any addons (in particular the VSCode one to edit configuration.yml).

One potentially useful bit of information is that I noticed that both internal and external URL were empty after the addon installation. I filled in the internal URL and some broken integrations started working again, however the issues with e.g. addons remained.

The following are the warnings and errors after restart:

2022-01-27 15:46:37 ERROR (MainThread) [homeassistant.components.hassio.handler] /supervisor/available_updates return code 500
2022-01-27 15:46:37 ERROR (MainThread) [homeassistant.components.hassio] Failed to to call /supervisor/available_updates -
2022-01-27 15:47:13 ERROR (MainThread) [homeassistant.components.hassio.handler] /supervisor/info return code 500
2022-01-27 15:47:13 WARNING (MainThread) [homeassistant.components.hassio] Can't read Supervisor data:

When I try to access the addons I get

2022-01-27 15:51:31 ERROR (MainThread) [homeassistant.components.hassio.handler] /supervisor/info return code 500
2022-01-27 15:51:31 ERROR (MainThread) [homeassistant.components.hassio] Failed to to call /supervisor/info -
2022-01-27 15:51:31 ERROR (MainThread) [homeassistant.components.hassio.handler] /addons return code 500
2022-01-27 15:51:31 ERROR (MainThread) [homeassistant.components.hassio] Failed to to call /addons -
2022-01-27 15:51:48 ERROR (MainThread) [homeassistant.components.hassio.handler] /supervisor/available_updates return code 500
2022-01-27 15:51:48 ERROR (MainThread) [homeassistant.components.hassio] Failed to to call /supervisor/available_updates -

Edited to add the system health in case it’s useful:

System Health

error failed to load: unknown
Home Assistant Cloud
logged_in false
can_reach_cert_server ok
can_reach_cloud_auth ok
can_reach_cloud ok
Home Assistant Supervisor
error failed to load: unknown
Lovelace
dashboards 2
resources 0
views 6
mode storage

Restarted HA again after having it running for a while. Pasting all warnings and errors I can find below:

2022-01-27 23:19:40 ERROR (MainThread) [homeassistant.components.hassio.handler] /supervisor/info return code 500
2022-01-27 23:19:40 WARNING (MainThread) [homeassistant.components.hassio] Can't read Supervisor data:
[debug messages from the http integration]
2022-01-27 23:19:40 DEBUG (MainThread) [homeassistant.components.websocket_api.http.connection] [547543160960] Received {'type': 'frontend/get_translations', 'language': 'en', 'category': 'state', 'config_flow': False, 'id': 21}
2022-01-27 23:19:40 DEBUG (MainThread) [homeassistant.components.websocket_api.http.connection] [547543160960] Received {'type': 'persistent_notification/get', 'id': 22}
2022-01-27 23:19:40 ERROR (MainThread) [homeassistant.components.hassio.handler] /ingress/panels return code 500
2022-01-27 23:19:40 ERROR (MainThread) [homeassistant.components.hassio.addon_panel] Can't read panel info:
2022-01-27 23:19:40 INFO (MainThread) [homeassistant.setup] Setup of domain hassio took 4.5 seconds
[...]
2022-01-27 23:19:40 DEBUG (MainThread) [homeassistant.components.websocket_api.http.connection] [547543160960] Sending {"id": 18, "type": "result", "success": true, "result": {"value": {"showAdvanced": true}}}
2022-01-27 23:19:40 DEBUG (MainThread) [homeassistant.components.websocket_api.http.connection] [547543160960] Received {'type': 'subscribe_bootstrap_integrations', 'id': 23}
2022-01-27 23:19:40 ERROR (MainThread) [homeassistant.config_entries] Error setting up entry Supervisor for hassio
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/config_entries.py", line 313, in async_setup
result = await component.async_setup_entry(hass, self) # type: ignore
File "/usr/src/homeassistant/homeassistant/components/hassio/__init__.py", line 637, in async_setup_entry
coordinator = HassioDataUpdateCoordinator(hass, entry, dev_reg)
File "/usr/src/homeassistant/homeassistant/components/hassio/__init__.py", line 715, in __init__
self.is_hass_os = "hassos" in get_info(self.hass)
TypeError: argument of type 'NoneType' is not iterable
2022-01-27 23:19:40 DEBUG (MainThread) [homeassistant.components.websocket_api.http.connection] [547543160960] Sending {"id": 23, "type": "result", "success": true, "result": null}
[...]
2022-01-27 23:19:46 INFO (SyncWorker_2) [homeassistant.loader] Loaded integration from homeassistant.components.integration
2022-01-27 23:19:46 INFO (MainThread) [homeassistant.setup] Setting up usb
2022-01-27 23:19:46 ERROR (MainThread) [homeassistant.setup] Error during setup of component usb
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/setup.py", line 229, in _async_setup_component
result = await task
File "/usr/src/homeassistant/homeassistant/components/usb/__init__.py", line 101, in async_setup
await usb_discovery.async_setup()
File "/usr/src/homeassistant/homeassistant/components/usb/__init__.py", line 132, in async_setup
await self._async_start_monitor()
File "/usr/src/homeassistant/homeassistant/components/usb/__init__.py", line 143, in _async_start_monitor
info = await system_info.async_get_system_info(self.hass)
File "/usr/src/homeassistant/homeassistant/helpers/system_info.py", line 56, in async_get_system_info
info_object["supervisor"] = info.get("supervisor")
AttributeError: 'NoneType' object has no attribute 'get'
2022-01-27 23:19:46 INFO (MainThread) [homeassistant.setup] Setup of domain logbook took 2.3 seconds
[....]
2022-01-27 23:19:54 ERROR (MainThread) [homeassistant.components.updater] Unexpected error fetching Home Assistant update data: 'NoneType' object is not subscriptable
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/helpers/update_coordinator.py", line 187, in _async_refresh
self.data = await self._async_update_data()
File "/usr/src/homeassistant/homeassistant/helpers/update_coordinator.py", line 147, in _async_update_data
return await self.update_method()
File "/usr/src/homeassistant/homeassistant/components/updater/__init__.py", line 82, in check_new_version
newest = core_info["version_latest"]
TypeError: 'NoneType' object is not subscriptable
[...]
2022-01-27 23:20:17 ERROR (MainThread) [homeassistant.setup] Unable to set up dependencies of default_config. Setup failed for dependencies: usb
2022-01-27 23:20:17 ERROR (MainThread) [homeassistant.setup] Setup failed for default_config: Could not set up all dependencies.
[...]
2022-01-27 23:20:18 ERROR (MainThread) [homeassistant.components.hassio.handler] /supervisor/info return code 500
2022-01-27 23:20:18 ERROR (MainThread) [homeassistant.components.hassio] Failed to to call /supervisor/info -
[...]
2022-01-27 23:20:19 ERROR (MainThread) [homeassistant.components.hassio.handler] /addons return code 500
2022-01-27 23:20:19 ERROR (MainThread) [homeassistant.components.hassio] Failed to to call /addons -
[...]
2022-01-27 23:20:20 ERROR (MainThread) [homeassistant.components.hassio.handler] /discovery return code 500
2022-01-27 23:20:20 ERROR (MainThread) [homeassistant.components.hassio.discovery] Can't read discover info:

For posterity I (seem to have?) fixed it by mounting the SD card on my computer and deleting an empty folder for letencrypt in the addons directory. I also deleted the sections for duckdns in the addons.json file. Not entirely sure which of these two did the trick.