0.88.1 broke mfi.py

I just updated and I can no longer see or control my UBNT mFi devices. I was just going to roll back, but read that since it’s probably a config issue that a change on the newer versions cause, I should try to fix instead. Problem is, I don’t know where to start.

I have reboot both mFi server and Hass separately. If I do both at the same time Hass tries to connect to mFi while it is still booting up, which gives the error for failure to connect and never ties again until Hass is resarted.

Here is the error info:

Error while setting up platform mfi
Traceback (most recent call last):
File "/srv/homeassistant/lib/python3.5/site-packages/homeassistant/helpers/entity_platform.py", line 128, in _async_setup_platform
SLOW_SETUP_MAX_WAIT, loop=hass.loop)
File "/usr/lib/python3.5/asyncio/tasks.py", line 400, in wait_for
return fut.result()
File "/usr/lib/python3.5/asyncio/futures.py", line 293, in result
raise self._exception
File "/usr/lib/python3.5/concurrent/futures/thread.py", line 55, in run
result = self.fn(*self.args, **self.kwargs)
File "/srv/homeassistant/lib/python3.5/site-packages/homeassistant/components/sensor/mfi.py", line 72, in setup_platform
for device in client.get_devices()
File "/srv/homeassistant/lib/python3.5/site-packages/mficlient/client.py", line 192, in get_devices
device = Device(self, devinfo['_id'])
KeyError: '_id'

Here is the config that has always worked in my configuration.yaml:

# mFi Switch
switch:
  - platform: mfi
    host: 10.100.0.199
    username: mfiuser
    password: mfipassword
    verify_ssl: False

# mFi Sensor and Weather prediction
sensor:
  - platform: mfi
    host: 10.100.0.199
    username: mfiuser
    password: mfipassword
    verify_ssl: False

This is the main thing I use Hass for since UBNT never made a Android app. I used to write bash and curl scripts invoked with php and use a http request app to turn on and turn off stuff, which gets pretty tedious when you need 2 scripts for each device.

As an update, I have tried rolling back to every version through 0.85.1. Still get same error so it broke something even a rollback can’t fix. I was on a 0.86.x, don’t remember which one exactly.

Started magically working again on 0.88.1. Not sure what fixed it.