Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error setting up entry Anna for plugwise - type conversion #67919

Closed
bart1970 opened this issue Mar 9, 2022 · 8 comments · Fixed by #68082
Closed

Error setting up entry Anna for plugwise - type conversion #67919

bart1970 opened this issue Mar 9, 2022 · 8 comments · Fixed by #68082
Assignees

Comments

@bart1970
Copy link

bart1970 commented Mar 9, 2022

The problem

When starting Home Assistant, I get a type error in the Anna plugin log. The integration is not set up. For exact error message, see the error log below.
I have been using the integration for a long time. In the 2022.3 release, it is not working anymore.

After reading #67687 I cannot make out if they are related.

What version of Home Assistant Core has the issue?

2022.3.0-2022.3.3

What was the last working version of Home Assistant Core?

2022.2.x

What type of installation are you running?

Home Assistant Supervised

Integration causing the issue

Anna Plugwise

Link to integration documentation on our website

No response

Diagnostics information

No response

Example YAML snippet

No response

Anything in the logs that might be useful for us?

Logfile of Anna integration:

Logger: homeassistant.config_entries
Source: components/plugwise/gateway.py:53
First occurred: March 8, 2022, 10:35:28 PM (1 occurrences)
Last logged: March 8, 2022, 10:35:28 PM

Error setting up entry Anna for plugwise
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/config_entries.py", line 335, in async_setup
    result = await component.async_setup_entry(hass, self)
  File "/usr/src/homeassistant/homeassistant/components/plugwise/__init__.py", line 13, in async_setup_entry
    return await async_setup_entry_gw(hass, entry)
  File "/usr/src/homeassistant/homeassistant/components/plugwise/gateway.py", line 53, in async_setup_entry_gw
    api.get_all_devices()
  File "/usr/local/lib/python3.9/site-packages/plugwise/smile.py", line 106, in get_all_devices
    self._all_device_data()
  File "/usr/local/lib/python3.9/site-packages/plugwise/smile.py", line 60, in _all_device_data
    data = self._get_device_data(device_id)
  File "/usr/local/lib/python3.9/site-packages/plugwise/smile.py", line 201, in _get_device_data
    device_data = self._get_appliance_data(dev_id)
  File "/usr/local/lib/python3.9/site-packages/plugwise/helper.py", line 897, in _get_appliance_data
    and self._outdoor_temp > data["cooling_activation_outdoor_temperature"]
TypeError: '>' not supported between instances of 'NoneType' and 'float'

Additional information

No response

@probot-home-assistant
Copy link

plugwise documentation
plugwise source
(message by IssueLinks)

@probot-home-assistant
Copy link

Hey there @CoMPaTech, @bouwew, @brefra, @frenck, mind taking a look at this issue as it has been labeled with an integration (plugwise) you are listed as a code owner for? Thanks!
(message by CodeOwnersMention)

@CoMPaTech
Copy link
Contributor

Thanks for creating this issue! As a first check, do you have a (outdoor!) temperature reading on your Anna (e.g. setup your zipcode)? Looking at the error it isn't set (and probably something to improve on), but we would like to know how/why it's at None.

@bart1970
Copy link
Author

bart1970 commented Mar 9, 2022

Hello,

I think I set this up somewhere in NL, not my home location. The. "Weerstation" of Anna contains: Geo-coordinates 52,6. Weerstation: Velp.
The Anna outdoor temperature is on my dashboard, so it used to be there.

Now also performed a test with adding my own zipcode and then restarting home assistant, but the same result.

If you want me to change any configuration to see if this helps, or If I need to fetch some data, just let me know.

@bouwew
Copy link
Contributor

bouwew commented Mar 10, 2022

@bart1970 What kind of heating(/cooling) device is connected to you Anna?
Also, do you happen to have an Adam as well?

@bart1970
Copy link
Author

bart1970 commented Mar 10, 2022

Hello, during my morning walk, I realized I missed to add that indeed.

I'm running an Elga version of the Anna.
Currently, my Anna integration contains 3 devices:

  • Anna
  • Elga
  • Smile Anna

The Elga also contains an outdoor entity: sensor.elga_outdoor_temperature.

Maybe this is the one that creates the problem?

Ah no, the Elga also contains a number of parameters that you can set. I think cooling_activation_outdoor_temperature is one of them. (Dutch: Warmtepomp gaat in koelingsmodus boven een buitentemperatuur van).
I have never seen this one in Home Assistant.

@bouwew
Copy link
Contributor

bouwew commented Mar 10, 2022

Thanks, that explains a little bit why this error is happening: we've been working on improving the plugwise integration with respect to heat pumps and cooling functionality. But as we don't have an Elga in our own systems, we cannot test. So there could be bugs, and here is one.

Would you please capture the data of your system as indicated here: https://github.com/plugwise/python-plugwise/tree/main/userdata
Scroll down to the Sharing topic for detailed instructions.

Also, we need to know, have you activated the cooling function? Or not?

@bouwew
Copy link
Contributor

bouwew commented Mar 10, 2022

I propose we continue this conversation here: plugwise/python-plugwise#158

@github-actions github-actions bot locked and limited conversation to collaborators Apr 12, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants