8000 Added pi-hole sensor rounding by fronzbot · Pull Request #8499 · home-assistant/core · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

Added pi-hole sensor rounding #8499
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

Merged
merged 1 commit into from
Jul 17, 2017
Merged

Added pi-hole sensor rounding #8499

merged 1 commit into from
Jul 17, 2017

Conversation

fronzbot
Copy link
Contributor

Description:

The pi-hole sensor grabs the raw API results from Pi-Hole which can have stupidly long decimals (specifically the percentage of ads blocked). I round to two decimals and wrap in a try/except to ensure future sensors that are added will still return states (i.e. when they are non-numeric).

Checklist:

  • Local tests with tox run successfully. Your PR cannot be merged unless tests pass

@mention-bot
Copy link

@fronzbot, thanks for your PR! By analyzing the history of the files in this pull request, we identified @fabaff and @colinodell to be potential reviewers.

Copy link
Member
@fabaff fabaff left a comment

Choose a reason for hiding this comment

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

Thanks 🐦

@fabaff fabaff merged commit 1a1571c into home-assistant:dev Jul 17, 2017
@balloob balloob mentioned this pull request Jul 29, 2017
dethpickle pushed a commit to dethpickle/home-assistant that referenced this pull request Aug 18, 2017
@home-assistant home-assistant locked and limited conversation to collaborators Oct 20, 2017
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.

4 participants
0