Skip to content

expose climate current temperature in prometeus metrics#15232

Merged
balloob merged 4 commits into
home-assistant:devfrom
stenius:prometheus_climate_current_temp
Jul 2, 2018
Merged

expose climate current temperature in prometeus metrics#15232
balloob merged 4 commits into
home-assistant:devfrom
stenius:prometheus_climate_current_temp

Conversation

@stenius
Copy link
Copy Markdown
Contributor

@stenius stenius commented Jun 30, 2018

Description:

Exposes current temperature in climate components to Prometheus exporter.

Before it just exposed the desired temperature.

Checklist:

  • The code change is tested and works locally.
  • Local tests pass with tox. Your PR cannot be merged unless tests pass

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

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

  • New dependencies have been added to the REQUIREMENTS variable (example).
  • New dependencies are only imported inside functions that use them (example).
  • New or updated dependencies have been added to requirements_all.txt by running script/gen_requirements_all.py.
  • New files were added to .coveragerc.

If the code does not interact with devices:

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

@homeassistant
Copy link
Copy Markdown
Contributor

Hi @stenius,

It seems you haven't yet signed a CLA. Please do so here.

Once you do that we will be able to review and accept this pull request.

Thanks!

@stenius stenius requested a review from a team as a code owner June 30, 2018 14:38
@ghost ghost added the in progress label Jun 30, 2018
Comment thread homeassistant/const.py Outdated
# Temperature attribute
ATTR_TEMPERATURE = 'temperature'

# Current Temperature attribute
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Please don't add this to main const but import it from climate component.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

I've removed this from the main constants and I'm now importing it from the climate component. Thanks.

Copy link
Copy Markdown
Contributor Author

@stenius stenius left a comment

Choose a reason for hiding this comment

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

changes made

@balloob balloob merged commit 31e23eb into home-assistant:dev Jul 2, 2018
@ghost ghost removed the in progress label Jul 2, 2018
@stenius stenius deleted the prometheus_climate_current_temp branch July 4, 2018 18:59
@stenius
Copy link
Copy Markdown
Contributor Author

stenius commented Jul 4, 2018

Thank you!

awarecan pushed a commit to awarecan/home-assistant that referenced this pull request Jul 16, 2018
…nt#15232)

* expose climate current temperature in prometeus metrics

* import ATTR_CURRENT_TEMPERATURE from climate instead of const

* remove duplicated ATTR_CURRENT_TEMPERATURE from const

* fix ATTR_CURRENT_TEMPERATURE import
@balloob balloob mentioned this pull request Jul 20, 2018
@awarecan awarecan mentioned this pull request Aug 9, 2018
@home-assistant home-assistant locked and limited conversation to collaborators Dec 10, 2018
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