[email protected], [email protected] component

I’ve pushed an update version to GitHub. Notable (and potentially breaking) changes:

  • The latest version of HA was complaining that the structure of the custom component won’t be supported in the future. Files for sensors, binary_sensors have been moved into the Miele folder. I am not sure how far backwards compatible that change is.
  • In the past, light was exposed as a binary_sensor that was indicating the status of the corresponding light. This has been removed. Instead lights are now exposed as such and can be toggled.
  • There is an miele.action service that can be used to invoke actions in the device (described in more detail https://www.miele.com/developer/swagger-ui/put_additional_info.html). Examples for the service data can be found in the pull request (https://github.com/docbobo/home-assistant-miele/pull/6)

@ATWindsor triggering all those things for your ventilation is a little bit tricky without documentation. Feel free to experiment with the action, perhaps you find something that’s not documented yet.

1 Like

Sorry to be such a hassle, but is there some kind of trouble-shooting opportunities if not appliances are found for some reason? 3 out of my 4 miele-things are found, and the gateway. But the last of 2 ovens is not found.

I copied the raw file to custom components and am getting the following errors relating to these files:

File “/config/custom_components/binary_sensor.py”, line 8, in
from custom_components.miele import DOMAIN as MIELE_DOMAIN, DATA_DEVICES
ImportError: cannot import name ‘DOMAIN’

and
File “/config/custom_components/sensor.py”, line 7, in
from custom_components.miele import DOMAIN as MIELE_DOMAIN, DATA_DEVICES
ImportError: cannot import name ‘DOMAIN’

File “/config/custom_components/light.py”, line 8, in
from custom_components.miele import DOMAIN as MIELE_DOMAIN, DATA_CLIENT, DATA_DEVICES
ImportError: cannot import name ‘DOMAIN’

can anyone help me solve these issues?

Any way to run this on hassio?

Can anyone help with getting Miele work on my Hass.io? I keep getting the same message and never get to the screen where i should input my data. what I have is the following:

Is this a new install of the Miele component? If not, I got around a similar error by deleting the .miele-token-cache file in the HA config directory. At that point, I could re-log-in to the Miele site and retrieve a new token. I didn’t have to get a new client ID/secret from Miele.

I tried to find that file but it isn’t there. Any other suggestions where i should look. I am using hass.io

If you haven’t gotten the Miele component working yet, that file probably doesn’t exist. The hass.io configuration directory is /usr/share/hassio/homeassistant I think (I’m using a regular Linux/pip install).

It’s not working, still the same message. I am using Hass.io and the directories /usr/share/hassio/homeassistant don’t exist. Very frustrating. Not even sure that this component works in Hass.io

Hi, have had this component working perfectly. Decided to update to 0.92 and now it stopped working. Had the message about wrong structure before, but I’ve re downloaded the component and put it in config\custom_components\miele but doesn’t work. In the log i get:
Setup failed for miele: Integration not found.

10:43 PM setup.py (ERROR)

Error loading custom_components.miele. Make sure all dependencies are installed

10:43 PM custom_components/miele/init.py (ERROR) - message first occured at 10:43 PM and shows up 2 times.

The last error also contains:

Error loading custom_components.miele. Make sure all dependencies are installed

Traceback (most recent call last): File “/usr/local/lib/python3.7/site-packages/homeassistant/loader.py”, line 263, in _load_file module = importlib.import_module(path) File “/usr/local/lib/python3.7/importlib/init.py”, line 127, in import_module return _bootstrap._gcd_import(name[level:], package, level) File “<frozen importlib._bootstrap>”, line 1006, in _gcd_import File “<frozen importlib._bootstrap>”, line 983, in _find_and_load File “<frozen importlib._bootstrap>”, line 967, in _find_and_load_unlocked File “<frozen importlib._bootstrap>”, line 677, in _load_unlocked File “<frozen importlib._bootstrap_external>”, line 728, in exec_module File “<frozen importlib._bootstrap>”, line 219, in _call_with_frames_removed File “/config/custom_components/miele/init.py”, line 13, in <module> from homeassistant.loader import get_platform ImportError: cannot import name ‘get_platform’ from ‘homeassistant.loader’ (/usr/local/lib/python3.7/site-packages/homeassistant/loader.py)

Hi @badmojo,

I saw the same issue and this patch fixes it for me.

1 Like

Great job, thanks for your work ! Would be great to see it integrated directly into HA as an official component !

Thanks Alot! That fixed it for me and the sensors came back. But today I got another error after a reboot, and now the sensors are gone again. I wish I knew how to code so I could fix this myself:

Log Details (ERROR)

Mon Apr 29 2019 15:51:03 GMT+0200 (centraleuropeisk sommartid)

Failed to retrieve devices: 401

Log Details (ERROR)
Mon Apr 29 2019 15:51:03 GMT+0200 (centraleuropeisk sommartid)
Error during setup of component miele
Traceback (most recent call last):
File “/usr/local/lib/python3.7/site-packages/homeassistant/setup.py”, line 153, in _async_setup_component
hass, processed_config)
File “/config/custom_components/miele/init.py”, line 130, in async_setup
hass.data[DOMAIN][DATA_DEVICES] = _to_dict(client.get_devices(lang))
File “/config/custom_components/miele/init.py”, line 98, in _to_dict
for item in items:
TypeError: ‘NoneType’ object is not iterable

Agree, where is the request page for official components?

First of all thx, for making this component.

I have just brought a new washer and want to intergrate it.
But i am getting the same error as in this issue.

https://github.com/docbobo/home-assistant-miele/issues/10

2019-05-03 19:32:54 ERROR (MainThread) [custom_components.miele.miele_at_home] Failed to retrieve devices: 401 2019-05-03 19:32:54 ERROR (MainThread) [homeassistant.setup] Error during setup of component miele Traceback (most recent call last): File "/usr/local/lib/python3.7/site-packages/homeassistant/setup.py", line 153, in _async_setup_component hass, processed_config) File "/config/custom_components/miele/__init__.py", line 130, in async_setup hass.data[DOMAIN][DATA_DEVICES] = _to_dict(client.get_devices(lang)) File "/config/custom_components/miele/__init__.py", line 98, in _to_dict for item in items: TypeError: 'NoneType' object is not iterable

Anyone know what is wrong?

Thx in advance

Thread bump! Got exactly the same error message, the custom component isn’t working since about two weeks.

Would love to support any developer that could look into the problem, either by aiding further analysis (other logs?) or trying out possible fixes. I’m not a dev myself.

This component was really helpful.

I get almost the same error message:
Traceback (most recent call last):
File “/srv/homeassistant/lib/python3.7/site-packages/homeassistant/setup.py”, line 151, in _async_setup_component
hass, processed_config)
File “/home/homeassistant/.homeassistant/custom_components/miele/init.py”, line 125, in async_setup
hass.data[DOMAIN][DATA_DEVICES] = _to_dict(client.get_devices(lang))
File “/home/homeassistant/.homeassistant/custom_components/miele/init.py”, line 94, in _to_dict
for item in items:
TypeError: ‘NoneType’ object is not iterable

According to this post Github issue the problem is on miele’s servers.
So nothing the developer can do anything about.
But maybe it would help if we all wrote a mail to them, telling them about the problem.
Any one know what to write to them?

Great idea. Let’s all email them and refer them to the Github issue.

I found this address: [email protected]

Will report back in this thread when I’ve sent my mail.

I got this message back from Miele:

Thank you for your email. Due to a server movement we’ve problems with some of our accounts.

May we ask you to help us finding the issue.

Please be so kind:

  • Generate a new access token
  • Send a new request to the API
  • If the failure still exist, please tell us the time of the day of your request.

Thank you very much for your support.

Kind regards

Miele 3rd party API Team