Upgraded from 0.57 to 0.60 and broke my install

Upgraded my ubuntu 16 vm that runs HAS using the upgrade command, all went through ok showing

no errors on upgrade, but now i cannot access HAS, nor HADashboard

both services show running, but i can access them from my PC

Here is a snip of the homeassistant log

2017-12-27 11:19:13 ERROR (MainThread) [homeassistant.loader] Error loading homeassistant.components.history. Make sure all dependencies are installed
Traceback (most recent call last):
File “/usr/local/lib/python3.5/dist-packages/homeassistant/loader.py”, line 142, in get_component
module = importlib.import_module(path)
File “/usr/lib/python3.5/importlib/init.py”, line 126, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
File “”, line 986, in _gcd_import
File “”, line 969, in _find_and_load
File “”, line 958, in _find_and_load_unlocked
File “”, line 673, in _load_unlocked
File “”, line 665, in exec_module
File “”, line 222, in _call_with_frames_removed
File “/usr/local/lib/python3.5/dist-packages/homeassistant/components/history.py”, line 20, in
from homeassistant.components.http import HomeAssistantView
File “/usr/local/lib/python3.5/dist-packages/homeassistant/components/http/init.py”, line 30, in
from .auth import auth_middleware
File “/usr/local/lib/python3.5/dist-packages/homeassistant/components/http/auth.py”, line 8, in
from aiohttp.web import middleware
ImportError: cannot import name ‘middleware’
2017-12-27 11:19:13 ERROR (MainThread) [homeassistant.loader] Unable to find component history
2017-12-27 11:19:13 ERROR (MainThread) [homeassistant.setup] Setup failed for history: Component not found.
2017-12-27 11:19:13 ERROR (MainThread) [homeassistant.loader] Error loading homeassistant.components.frontend. Make sure all dependencies are installed
Traceback (most recent call last):
File “/usr/local/lib/python3.5/dist-packages/homeassistant/loader.py”, line 142, in get_component
module = importlib.import_module(path)
File “/usr/lib/python3.5/importlib/init.py”, line 126, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
File “”, line 986, in _gcd_import
File “”, line 969, in _find_and_load
File “”, line 958, in _find_and_load_unlocked
File “”, line 673, in _load_unlocked
File “”, line 665, in exec_module
File “”, line 222, in _call_with_frames_removed
File “/usr/local/lib/python3.5/dist-packages/homeassistant/components/frontend/init.py”, line 19, in
from homeassistant.components.http import HomeAssistantView
File “/usr/local/lib/python3.5/dist-packages/homeassistant/components/http/init.py”, line 30, in
from .auth import auth_middleware
File “/usr/local/lib/python3.5/dist-packages/homeassistant/components/http/auth.py”, line 8, in
from aiohttp.web import middleware
ImportError: cannot import name ‘middleware’
2017-12-27 11:19:13 ERROR (MainThread) [homeassistant.loader] Unable to find component frontend
2017-12-27 11:19:13 ERROR (MainThread) [homeassistant.setup] Setup failed for frontend: Component not found.
2017-12-27 11:19:13 INFO (MainThread) [homeassistant.core] Bus:Handling <Event call_service[L]: service=create, service_call_id=139854656888960-1, domain=persistent_notification, service_data=message=The following components and platforms could not be set up:

  • history

Please check your config., title=Invalid config, notification_id=invalid_config>
2017-12-27 11:19:13 INFO (MainThread) [homeassistant.core] Bus:Handling <Event call_service[L]: service=create, service_call_id=139854656888960-2, domain=persistent_notification, service_data=message=The following components and platforms could not be set up:

  • frontend
  • history

Please check your config., title=Invalid config, notification_id=invalid_config>
2017-12-27 11:19:13 INFO (MainThread) [homeassistant.core] Bus:Handling <Event state_changed[L]: new_state=<state persistent_notification.invalid_config=notifying; message=The following components and platforms could not be set up:

  • history

Please check your config., title=Invalid config @ 2017-12-27T11:19:13.637601+11:00>, old_state=None, entity_id=persistent_notification.invalid_config>
2017-12-27 11:19:13 INFO (MainThread) [homeassistant.core] Bus:Handling <Event service_executed[L]: service_call_id=139854656888960-1>
2017-12-27 11:19:13 INFO (MainThread) [homeassistant.core] Bus:Handling <Event service_registered[L]: service=set_level, domain=logger>
2017-12-27 11:19:13 INFO (MainThread) [homeassistant.setup] Setup of domain logger took 0.1 seconds.
2017-12-27 11:19:13 INFO (MainThread) [homeassistant.core] Bus:Handling <Event component_loaded[L]: component=logger>
2017-12-27 11:19:13 INFO (MainThread) [homeassistant.core] Bus:Handling <Event state_changed[L]: new_state=<state persistent_notification.invalid_config=notifying; message=The following components and platforms could not be set up:

  • frontend
  • history

Please check your config., title=Invalid config @ 2017-12-27T11:19:13.637601+11:00>, old_state=<state persistent_notification.invalid_config=notifying; message=The following components and platforms could not be set up:

  • history

Please check your config., title=Invalid config @ 2017-12-27T11:19:13.637601+11:00>, entity_id=persistent_notification.invalid_config>
2017-12-27 11:19:13 INFO (MainThread) [homeassistant.core] Bus:Handling <Event service_executed[L]: service_call_id=139854656888960-2>
2017-12-27 11:19:13 INFO (MainThread) [homeassistant.loader] Loaded wemo from homeassistant.components.wemo
2017-12-27 11:19:13 ERROR (MainThread) [homeassistant.loader] Error loading homeassistant.components.http. Make sure all dependencies are installed
Traceback (most recent call last):
File “/usr/local/lib/python3.5/dist-packages/homeassistant/loader.py”, line 142, in get_component
module = importlib.import_module(path)
File “/usr/lib/python3.5/importlib/init.py”, line 126, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
File “”, line 986, in _gcd_import
File “”, line 969, in _find_and_load
File “”, line 958, in _find_and_load_unlocked
File “”, line 673, in _load_unlocked
File “”, line 665, in exec_module
File “”, line 222, in _call_with_frames_removed
File “/usr/local/lib/python3.5/dist-packages/homeassistant/components/http/init.py”, line 30, in
from .auth import auth_middleware
File “/usr/local/lib/python3.5/dist-packages/homeassistant/components/http/auth.py”, line 8, in
from aiohttp.web import middleware
ImportError: cannot import name ‘middleware’
2017-12-27 11:19:13 ERROR (MainThread) [homeassistant.loader] Unable to find component http
2017-12-27 11:19:13 ERROR (MainThread) [homeassistant.setup] Setup failed for http: Component not found.
2017-12-27 11:19:13 ERROR (MainThread) [homeassistant.loader] Error loading homeassistant.components.conversation. Make sure all dependencies are installed
Traceback (most recent call last):
File “/usr/local/lib/python3.5/dist-packages/homeassistant/loader.py”, line 142, in get_component
module = importlib.import_module(path)
File “/usr/lib/python3.5/importlib/init.py”, line 126, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
File “”, line 986, in _gcd_import
File “”, line 969, in _find_and_load
File “”, line 958, in _find_and_load_unlocked
File “”, line 673, in _load_unlocked
File “”, line 665, in exec_module
File “”, line 222, in _call_with_frames_removed
File “/usr/local/lib/python3.5/dist-packages/homeassistant/components/conversation.py”, line 19, in
from homeassistant.components import http
File “/usr/local/lib/python3.5/dist-packages/homeassistant/components/http/init.py”, line 30, in
from .auth import auth_middleware
File “/usr/local/lib/python3.5/dist-packages/homeassistant/components/http/auth.py”, line 8, in
from aiohttp.web import middleware
ImportError: cannot import name ‘middleware’
2017-12-27 11:19:13 ERROR (MainThread) [homeassistant.loader] Unable to find component conversation
2017-12-27 11:19:13 ERROR (MainThread) [homeassistant.setup] Setup failed for conversation: Component not found.
2017-12-27 11:19:14 ERROR (MainThread) [homeassistant.loader] Error loading homeassistant.components.media_player. Make sure all dependencies are installed
Traceback (most recent call last):
File “/usr/local/lib/python3.5/dist-packages/homeassistant/loader.py”, line 142, in get_component
module = importlib.import_module(path)
File “/usr/lib/python3.5/importlib/init.py”, line 126, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
File “”, line 986, in _gcd_import
File “”, line 969, in _find_and_load
File “”, line 958, in _find_and_load_unlocked
File “”, line 673, in _load_unlocked
File “”, line 665, in exec_module
File “”, line 222, in _call_with_frames_removed
File “/usr/local/lib/python3.5/dist-packages/homeassistant/components/media_player/init.py”, line 21, in
from homeassistant.components.http import KEY_AUTHENTICATED, HomeAssistantView
File “/usr/local/lib/python3.5/dist-packages/homeassistant/components/http/init.py”, line 30, in
from .auth import auth_middleware
File “/usr/local/lib/python3.5/dist-packages/homeassistant/components/http/auth.py”, line 8, in
from aiohttp.web import middleware
ImportError: cannot import name ‘middleware’
2017-12-27 11:19:14 ERROR (MainThread) [homeassistant.loader] Unable to find component media_player
2017-12-27 11:19:14 ERROR (MainThread) [homeassistant.setup] Setup failed for media_player: Component not found.
2017-12-27 11:19:14 INFO (MainThread) [homeassistant.loader] Loaded light from homeassistant.components.light
2017-12-27 11:19:14 INFO (MainThread) [homeassistant.loader] Loaded group from homeassistant.components.group
2017-12-27 11:19:14 INFO (MainThread) [homeassistant.loader] Loaded light.limitlessled from homeassistant.components.light.limitlessled
2017-12-27 11:19:14 INFO (MainThread) [homeassistant.loader] Loaded light.flux_led from homeassistant.components.light.flux_led
2017-12-27 11:19:14 ERROR (MainThread) [homeassistant.loader] Error loading homeassistant.components.logbook. Make sure all dependencies are installed
Traceback (most recent call last):
File “/usr/local/lib/python3.5/dist-packages/homeassistant/loader.py”, line 142, in get_component
module = importlib.import_module(path)
File “/usr/lib/python3.5/importlib/init.py”, line 126, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
File “”, line 986, in _gcd_import
File “”, line 969, in _find_and_load
File “”, line 958, in _find_and_load_unlocked
File “”, line 673, in _load_unlocked
File “”, line 665, in exec_module
File “”, line 222, in _call_with_frames_removed
File “/usr/local/lib/python3.5/dist-packages/homeassistant/components/logbook.py”, line 18, in
from homeassistant.components.http import HomeAssistantView
File “/usr/local/lib/python3.5/dist-packages/homeassistant/components/http/init.py”, line 30, in
from .auth import auth_middleware
File “/usr/local/lib/python3.5/dist-packages/homeassistant/components/http/auth.py”, line 8, in
from aiohttp.web import middleware
ImportError: cannot import name ‘middleware’
2017-12-27 11:19:14 ERROR (MainThread) [homeassistant.loader] Unable to find component logbook
2017-12-27 11:19:14 ERROR (MainThread) [homeassistant.setup] Setup failed for logbook: Component not found.
2017-12-27 11:19:14 INFO (MainThread) [homeassistant.setup] Setting up group
2017-12-27 11:19:14 INFO (MainThread) [homeassistant.loader] Loaded sensor from homeassistant.components.sensor
2017-12-27 11:19:14 INFO (MainThread) [homeassistant.loader] Loaded sensor.time_date from homeassistant.components.sensor.time_date
2017-12-27 11:19:14 INFO (MainThread) [homeassistant.loader] Loaded sensor.efergy from homeassistant.components.sensor.efergy
2017-12-27 11:19:14 INFO (MainThread) [homeassistant.loader] Loaded sensor.plex from homeassistant.components.sensor.plex
2017-12-27 11:19:14 INFO (MainThread) [homeassistant.loader] Loaded sensor.darksky from homeassistant.components.sensor.darksky
2017-12-27 11:19:14 INFO (MainThread) [homeassistant.setup] Setting up sensor
2017-12-27 11:19:14 INFO (MainThread) [homeassistant.loader] Loaded notify from homeassistant.components.notify
2017-12-27 11:19:14 INFO (MainThread) [homeassistant.loader] Loaded notify.telstra from homeassistant.components.notify.telstra
2017-12-27 11:19:14 INFO (MainThread) [homeassistant.setup] Setting up notify
2017-12-27 11:19:14 ERROR (MainThread) [homeassistant.loader] Error loading homeassistant.components.automation. Make sure all dependencies are installed
Traceback (most recent call last):
File “/usr/local/lib/python3.5/dist-packages/homeassistant/loader.py”, line 142, in get_component
module = importlib.import_module(path)
File “/usr/lib/python3.5/importlib/init.py”, line 126, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
File “”, line 986, in _gcd_import
File “”, line 969, in _find_and_load
File “”, line 958, in _find_and_load_unlocked
File “”, line 673, in _load_unlocked
File “”, line 665, in exec_module
File “”, line 222, in _call_with_frames_removed
File “/usr/local/lib/python3.5/dist-packages/homeassistant/components/automation/init.py”, line 21, in
from homeassistant.components import logbook
File “/usr/local/lib/python3.5/dist-packages/homeassistant/components/logbook.py”, line 18, in
from homeassistant.components.http import HomeAssistantView
File “/usr/local/lib/python3.5/dist-packages/homeassistant/components/http/init.py”, line 30, in
from .auth import auth_middleware
File “/usr/local/lib/python3.5/dist-packages/homeassistant/components/http/auth.py”, line 8, in
from aiohttp.web import middleware
ImportError: cannot import name ‘middleware’
2017-12-27 11:19:14 ERROR (MainThread) [homeassistant.loader] Unable to find component automation
2017-12-27 11:19:14 ERROR (MainThread) [homeassistant.setup] Setup failed for automation: Component not found.
2017-12-27 11:19:14 INFO (MainThread) [homeassistant.loader] Loaded sun from homeassistant.components.sun
2017-12-27 11:19:14 INFO (MainThread) [homeassistant.setup] Setting up sun
2017-12-27 11:19:15 INFO (MainThread) [homeassistant.setup] Setup of domain sun took 0.1 seconds.
2017-12-27 11:19:15 INFO (MainThread) [homeassistant.core] Bus:Handling <Event component_loaded[L]: component=sun>
2017-12-27 11:19:15 ERROR (MainThread) [homeassistant.loader] Error loading homeassistant.components.device_tracker. Make sure all dependencies are installed
Traceback (most recent call last):
File “/usr/local/lib/python3.5/dist-packages/homeassistant/loader.py”, line 142, in get_component
module = importlib.import_module(path)
File “/usr/lib/python3.5/importlib/init.py”, line 126, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
File “”, line 986, in _gcd_import
File “”, line 969, in _find_and_load
File “”, line 958, in _find_and_load_unlocked
File “”, line 673, in _load_unlocked
File “”, line 665, in exec_module
File “”, line 222, in _call_with_frames_removed
File “/usr/local/lib/python3.5/dist-packages/homeassistant/components/device_tracker/init.py”, line 27, in
from homeassistant.helpers.restore_state import async_get_last_state
File “/usr/local/lib/python3.5/dist-packages/homeassistant/helpers/restore_state.py”, line 11, in
from homeassistant.components.history import get_states, last_recorder_run
File “/usr/local/lib/python3.5/dist-packages/homeassistant/components/history.py”, line 20, in
from homeassistant.components.http import HomeAssistantView
File “/usr/local/lib/python3.5/dist-packages/homeassistant/components/http/init.py”, line 30, in
from .auth import auth_middleware
File “/usr/local/lib/python3.5/dist-packages/homeassistant/components/http/auth.py”, line 8, in
from aiohttp.web import middleware
ImportError: cannot import name ‘middleware’
2017-12-27 11:19:15 ERROR (MainThread) [homeassistant.loader] Unable to find component device_tracker
2017-12-27 11:19:15 ERROR (MainThread) [homeassistant.setup] Setup failed for device_tracker: Component not found.
2017-12-27 11:19:15 INFO (MainThread) [homeassistant.loader] Loaded discovery from homeassistant.components.discovery
2017-12-27 11:19:15 INFO (MainThread) [homeassistant.core] Bus:Handling <Event call_service[L]: service=create, service_call_id=139854656888960-3, domain=persistent_notification, service_data=message=The following components and platforms could not be set up:

Ymmv

  1. Stop Home Assistant
  2. Find your deps/ folder (in the same folder as your configuration.yaml) and delete everything in it (or just delete it)
  3. Start Home Assistant
1 Like

Quick mini thread hijack…

@Tinkerer - I saw you post this recently to fix another problem, but the deps folder on my install is permanently empty. I think I read somewhere that they moved the deps elsewhere, but I don’t know where. Should it have moved back at some point?

If I delete the folder itself it always magically reappears, but it’s always empty so if this advice was to fix my install it wouldn’t work. Any ideas?

If you’re getting the middleware error, then removing the deps/ folder from the location I provided above is the official fix.

If you’re getting a different error, you need to tell us what it is :wink:

Ha, I’m not getting any errors, but I was just curious what benefits there were to deleting an empty folder and why said folder that no longer appears to be required keeps reappearing when one does delete it.

Well, if you’re not getting the middleware error then this isn’t going to fix it :wink:

In this case, the middleware error is to do with outdated dependencies left in the deps/ folder, that HA doesn’t clean up automatically. The fix is to remove the files (or the folder for ease).

Thank you,
After the update to .60 I couldn’t connect to it although it was running; I renamed the
deps/ folder because I am paranoid that way and it worked fine after that.

Thank you @Tinkerer that resolve my issue