Skip to content

Add iaqualink binary sensor and unique_id#26616

Merged
MartinHjelmare merged 3 commits into
home-assistant:devfrom
flz:iaqualink-binary-sensor
Sep 14, 2019
Merged

Add iaqualink binary sensor and unique_id#26616
MartinHjelmare merged 3 commits into
home-assistant:devfrom
flz:iaqualink-binary-sensor

Conversation

@flz
Copy link
Copy Markdown
Contributor

@flz flz commented Sep 13, 2019

Description:

This PR introduces a new binary_sensor platform solving the issue with the freeze_protection sensor not being identified properly.

This also introduces the use of unique_id for all existing platforms to allow future multi-pool support.

Pull request with documentation for home-assistant.io (if applicable): home-assistant/home-assistant.io#10354

Checklist:

  • The code change is tested and works locally.
  • Local tests pass with tox. Your PR cannot be merged unless tests pass
  • There is no commented out code in this PR.
  • I have followed the development checklist

If user exposed functionality or configuration variables are added/changed:

If the code communicates with devices, web services, or third-party tools:

  • The manifest file has all fields filled out correctly. Update and include derived files by running python3 -m script.hassfest.
  • New or updated dependencies have been added to requirements_all.txt by running python3 -m script.gen_requirements_all.
  • Untested files have been added to .coveragerc.

If the code does not interact with devices:

  • Tests have been added to verify that the new code works.

@flz
Copy link
Copy Markdown
Contributor Author

flz commented Sep 13, 2019

Documentation at home-assistant/home-assistant.io#10354.

@flz
Copy link
Copy Markdown
Contributor Author

flz commented Sep 13, 2019

@MartinHjelmare Is this a worthy 0.99 fix?

Comment thread homeassistant/components/iaqualink/__init__.py Outdated
Comment thread homeassistant/components/iaqualink/__init__.py Outdated
@MartinHjelmare
Copy link
Copy Markdown
Member

MartinHjelmare commented Sep 13, 2019

No, we won't add it to 0.99 since it's a new platform and new features.

@MartinHjelmare
Copy link
Copy Markdown
Member

Why does the entity_id change when we add the unique_id?

@flz
Copy link
Copy Markdown
Contributor Author

flz commented Sep 13, 2019

Why does the entity_id change when we add the unique_id?

I can't seem to reproduce but it was the case yesterday when I overrode unique_id.

I've removed the integration, turned it back on (without unique_id), stopped HA, added unique_id, restarted HA and entity names didn't change this time.

@flz flz force-pushed the iaqualink-binary-sensor branch from d148711 to bf20b4a Compare September 13, 2019 16:18
Comment thread homeassistant/components/iaqualink/binary_sensor.py Outdated
Comment thread homeassistant/components/iaqualink/__init__.py Outdated
Copy link
Copy Markdown
Member

@MartinHjelmare MartinHjelmare left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice!

@MartinHjelmare MartinHjelmare changed the title Add binary_platform to iaqualink integration, add unique_id Add iaqualink binary sensor and unique_id Sep 14, 2019
@MartinHjelmare MartinHjelmare merged commit a71cd6e into home-assistant:dev Sep 14, 2019
@lock lock Bot locked and limited conversation to collaborators Sep 15, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants