Error after upgrade to 0.46

Hi forum.

Need help as HA showing error after latest upgrade to 0.46. Seems that it cant upgrade several packages. This is some text from my home-assistant.log file:

2017-06-05 18:48:49 WARNING (MainThread) [homeassistant.setup] Setup of sensor is taking over 10 seconds.
2017-06-05 18:48:49 WARNING (MainThread) [homeassistant.setup] Setup of media_player is taking over 10 seconds.
2017-06-05 18:49:01 ERROR (Thread-12) [homeassistant.util.package] Unable to install package netdisco==1.0.1: Command "/srv/homeassistant/bin/python3 -u -c "import setuptools, tokenize;__file__='/tmp/pip-build-hgkkeho5/netifaces/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" install --record /tmp/pip-bpn90cci-record/install-record.txt --single-version-externally-managed --compile --install-headers /srv/homeassistant/include/site/python3.4/netifaces --home=/tmp/tmpzie0zabf" failed with error code 1 in /tmp/pip-build-hgkkeho5/netifaces/
2017-06-05 18:49:01 ERROR (MainThread) [homeassistant.setup] Not initializing discovery because could not install dependency netdisco==1.0.1
2017-06-05 18:49:01 ERROR (MainThread) [homeassistant.setup] Setup failed for discovery: Could not install all requirements.
2017-06-05 18:49:12 WARNING (MainThread) [homeassistant.setup] Setup of tts is taking over 10 seconds.
2017-06-05 18:49:40 ERROR (Thread-7) [homeassistant.util.package] Unable to install package zeroconf==0.19.0: Command "/srv/homeassistant/bin/python3 -u -c "import setuptools, tokenize;__file__='/tmp/pip-build-leao66zt/netifaces/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" install --record /tmp/pip-4ie_dprr-record/install-record.txt --single-version-externally-managed --compile --install-headers /srv/homeassistant/include/site/python3.4/netifaces --home=/tmp/tmpdmkp_x1w" failed with error code 1 in /tmp/pip-build-leao66zt/netifaces/
2017-06-05 18:49:40 ERROR (MainThread) [homeassistant.setup] Not initializing zeroconf because could not install dependency zeroconf==0.19.0
2017-06-05 18:49:40 ERROR (MainThread) [homeassistant.setup] Setup failed for zeroconf: Could not install all requirements.
2017-06-05 18:49:40 ERROR (MainThread) [homeassistant.setup] Unable to setup dependencies of ios. Setup failed for dependencies: zeroconf
2017-06-05 18:49:40 ERROR (MainThread) [homeassistant.setup] Setup failed for ios: Could not setup all dependencies.
2017-06-05 18:51:00 ERROR (Thread-8) [homeassistant.util.package] Unable to install package pychromecast==0.8.1: Command "/srv/homeassistant/bin/python3 -u -c "import setuptools, tokenize;__file__='/tmp/pip-build-s30bc7o7/netifaces/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" install --record /tmp/pip-13unyinm-record/install-record.txt --single-version-externally-managed --compile --install-headers /srv/homeassistant/include/site/python3.4/netifaces --home=/tmp/tmphdgyatd1" failed with error code 1 in /tmp/pip-build-s30bc7o7/netifaces/
2017-06-05 18:51:00 ERROR (MainThread) [homeassistant.setup] Not initializing media_player.cast because could not install dependency pychromecast==0.8.1
2017-06-05 18:51:00 ERROR (MainThread) [homeassistant.setup] Unable to prepare setup for platform media_player.cast: Could not install all requirements.
2017-06-05 18:52:41 ERROR (Thread-9) [homeassistant.util.package] Unable to install package pychromecast==0.8.1: Command "/srv/homeassistant/bin/python3 -u -c "import setuptools, tokenize;__file__='/tmp/pip-build-xsj4o44e/netifaces/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" install --record /tmp/pip-2ye_q4gj-record/install-record.txt --single-version-externally-managed --compile --install-headers /srv/homeassistant/include/site/python3.4/netifaces --home=/tmp/tmp01qbo3ln" failed with error code 1 in /tmp/pip-build-xsj4o44e/netifaces/
2017-06-05 18:52:41 ERROR (MainThread) [homeassistant.setup] Not initializing media_player.cast because could not install dependency pychromecast==0.8.1
2017-06-05 18:52:41 ERROR (MainThread) [homeassistant.setup] Unable to prepare setup for platform media_player.cast: Could not install all requirements.
2017-06-05 18:54:46 ERROR (Thread-12) [homeassistant.util.package] Unable to install package pyatv==0.2.1: Command "/srv/homeassistant/bin/python3 -u -c "import setuptools, tokenize;__file__='/tmp/pip-build-eb8x3ucz/netifaces/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" install --record /tmp/pip-qnkdgszf-record/install-record.txt --single-version-externally-managed --compile --install-headers /srv/homeassistant/include/site/python3.4/netifaces --home=/tmp/tmpzc0naowl" failed with error code 1 in /tmp/pip-build-eb8x3ucz/netifaces/
2017-06-05 18:54:46 ERROR (MainThread) [homeassistant.setup] Not initializing media_player.apple_tv because could not install dependency pyatv==0.2.1
2017-06-05 18:54:46 ERROR (MainThread) [homeassistant.setup] Unable to prepare setup for platform media_player.apple_tv: Could not install all requirements.
2017-06-05 19:11:18 WARNING (MainThread) [homeassistant.helpers.entity] Update of sensor.network_up is taking over 10 seconds
2017-06-05 19:42:18 WARNING (MainThread) [homeassistant.helpers.entity] Update of sensor.network_up is taking over 10 seconds

Updated OS prior to upgrade and used the guide from HA website which has been working always.

Any ideas?

Forgot to mention; HA is running and says version 0.46, so when I try the upgrade one more time, it says that HA is the latest version.

Also an “Invalid config” box shows up on the dashboard saying that mediaplayer.appletv, discovery, zeroconf, media_player.cast and ios could not be set up.

/Kaspar

Anyone?

I still need help fixing this issue. Several functions in HA not working after the upgrade :frowning:

I had similar errors, not too long ago. I think in .45 and once again in .46. In my case I needed to change to my virtual user, activate the virtual environment, and then manually upgrade the packages which are not installing. You have a few, netdisco, zeroconf, and pychromecast. Unfortuantly, I can’t find the command at the moment, but once activated in the virtual environment it should be something like PIP install netdisco==1.0.1

Do that for each dependency which is failing in your log.

I too had that issue after upgrading HASS without activating the virtualenv! My solution was to go to the config folder and delete the “deps” folder. Also completely uninstall HASS outside the virtualenv. Then activate the venv and update. It should fix it.

Thanky you very much for the proposed solutions. I gives me more errors when trying to install the modules manually though.

The last way out is to start over again with a fresh Hasbian image and re-configure HA and other things. It may be the way to go for me now :frowning:

Once more, thanks for your time guys …

@KBrygger
I’m in the same exact situation for the past week or so.

I just rolled back to 0.45.1 and manually installed the missing dependencies / packages.

I was in the same situation when I tried to upgrade from 0.44.1 to 0.45… I did a fresh install and everything works like a charm now ( so in case everything fails, you can still go that way :stuck_out_tongue: )

Would be nice to only do a roll-back. How do you revert to previous version?

sudo systemctl stop [email protected]
sudo su -s /bin/bash homeassistant
source /srv/homeassistant/bin/activate
pip3 install --upgrade homeassistant==0.45.1
exit
sudo systemctl start [email protected]

1 Like

Another way I did, just because was:

sudo systemctl stop [email protected]
sudo su -s /bin/bash homeassistant
source /srv/homeassistant/bin/activate
pip3 uninstall homeassistant
hass --version (Just to Check)
pip3 install homeassistant=0.45.1
hass --version (Just to Check)
exit
sudo systemctl start [email protected]

1 Like

Thanks for that. I’ll try this when I get home from work as I do not have access from here :slight_smile:

If anybody is interested I’ll post the result of the downgrade in here…

After manually installing/upgrading all of the missing python packages in my virtual environment, 0.46 seems to be running well for me. I had a little trouble with python-openzwave until i installed the exact version 0.4.0.31.