galletn / iaqualink

Home Assistant Iaqualink Vacuums Robots
10 stars 2 forks source link

Integration fails during initialization #39

Open OtisPresley opened 3 days ago

OtisPresley commented 3 days ago

After installing the integration, adding the following to configuration.yaml and restarting HA, the addon fails with the following log entry:

vacuum:
  - platform: iaqualinkRobots
    username: <REMOVED>
    password: <REMOVED>
    api_key: EOOEMOW4YR6QNB07
    name: Poolio
Logger: homeassistant.helpers.entity
Source: helpers/entity.py:942
First occurred: 7:35:38 PM (27 occurrences)
Last logged: 7:48:36 PM

Update for vacuum.poolio fails
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 942, in async_update_ha_state
    await self.async_device_update()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1300, in async_device_update
    await self.async_update()
  File "/config/custom_components/iaqualinkRobots/vacuum.py", line 427, in async_update
    self._model = data['model']
                  ~~~~^^^^^^^^^
KeyError: 'model'

I assume the integration is using https://iaqualink.zodiacpoolsystems.com/. When I go there, my robot always shows Offline. Zodiac support says it doesn’t work standalone in the web page. The robot works just fine using the iaqualink app.

The question is, does this integration require the vacuum to be integrated with a pool system to work? I have the Polaris VRX IQ+

ppastur commented 3 days ago

The question is, does this integration require the vacuum to be integrated with a pool system to work? I have the Polaris VRX IQ+

My experience is that the robot does NOT need to be integrated with your pool system.

galletn commented 22 hours ago

Hi @OtisPresley,

could you reset your pw and send over your credentials to me?

nicolas.gallet@skynet.be

That will be the easiest way to check what your model is returning.

is it a brand new robot?

my first guess would be it does not support the features call anymore... I can wrap it with try catch pretty easy but it makes my life easier to know for sure!

    #Get model only first time to avoid load.
        if self._model == None:
            data = None
            url = URL_GET_DEVICE_FEATURES + self._serial_number + "/features"
            data =  await asyncio.wait_for(self.get_device_features(url), timeout=30)

            self._model = data['model']
            self._attributes['model'] = self._model
galletn commented 22 hours ago

and the other person that had similar issue was fixed with this part: https://github.com/galletn/iaqualink/commit/c7bd41e6f7a0bc10480c644ad45b8b47530c223f

there were multiple devices registered to the account resulting in the wrong one being taken.

maybe you have the same kind of situation? Maybe an additional filter is needed for other device types.

OtisPresley commented 21 hours ago

Thanks @galletn! I sent you an email with the credentials. The iaqualink app on my phone did make me enter the new credentials after changing the password, so the linkage is there but the website always shows my robot offline. This is the only device in my account.

The robot is not new. I have had it well over a year. I have tried this integration several times during that time, and it has always been the same. Based on what Zodiac support told me, I just never reached out until now.