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

Fix ZHA temperature sensor restoration #30661

Merged
merged 2 commits into from
Jan 11, 2020

Conversation

Adminiuga
Copy link
Contributor

Description:

  • Don't restore unit_of_measurement for ZHA sensors.
  • Correctly restore ZHA temperature sensor state if unit_system == "imperial"

Related issue (if applicable): fixes #30622

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.

@probot-home-assistant
Copy link

Hey there @dmulcahey, @Adminiuga, mind taking a look at this pull request as its been labeled with a integration (zha) you are listed as a codeowner for? Thanks!

@probot-home-assistant probot-home-assistant bot added has-tests small-pr PRs with less than 30 lines. labels Jan 11, 2020
@dmulcahey dmulcahey merged commit 008dddb into home-assistant:dev Jan 11, 2020
balloob pushed a commit that referenced this pull request Jan 11, 2020
* Add test for restoring state for zha temp.

* Don't restore unit of measurement for ZHA sensors.

Properly restore ZHA temperature sensor state.
@lock lock bot locked and limited conversation to collaborators Jan 12, 2020
@Adminiuga Adminiuga deleted the test/zha-sensor-temp branch January 15, 2020 02:25
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.

Temperature reported incorrectly from sensors
4 participants