Tradfri issue with 0.67.0

Hey everyone, getting an error trying to connect my Ikea Tradfri bulbs on 0.67:

2018-04-14 10:32:46 ERROR (MainThread) [homeassistant.core] Error doing job: Task exception was never retrieved
Traceback (most recent call last):
File “/usr/src/app/homeassistant/helpers/entity_platform.py”, line 258, in _async_add_entity
await entity.async_added_to_hass()
File “/usr/src/app/homeassistant/components/sensor/tradfri.py”, line 52, in async_added_to_hass
self._async_start_observe()
File “/usr/src/app/homeassistant/components/sensor/tradfri.py”, line 92, in _async_start_observe
from pytradfri.error import PytradfriError
ImportError: cannot import name ‘PytradfriError’

Done a fair bit of googling but can’t seem to find a solution… any ideas? Sorry if I missed something obvious

Looks like I have the same issue on docker.

Hi , have you already acchived a solution?

No not yet, there is a GitHub issue, I think it may be due to a mismatch in a pytradfri library but that’s just my guess right now. When I get home from food shopping I’ll carry on trying to figure it out :stuck_out_tongue:

sysrun came up with a workaround: downgrage pytadfri to 5.4.1

Inside the docker - pip uninstall pytradfri && pip install pytradfri==5.4.1

or change dockerfile (from sysrun):

"Run a patched Dockerfile with following content:

FROM homeassistant/home-assistant:0.67.0
RUN pip3 install pytradfri==5.4.1"

According to this github issue, you can get around this problem if you delete the deps directory inside your config dir.
Worked for me and my docker at least! And it worked well enough for them to close the issue.

1 Like

This did the trick! I my case: solved! Thanks.

Deleting pytradri directories from deps also fixed my issue! Thanks!