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
Remove last_reset_type and convert all those sensors to TOTAL_INCREASING #2233
Conversation
Hey there @stevebaxter, mind taking a look at this pull request as it has been labeled with an integration ( |
Hey there @sourabhjaiswal, mind taking a look at this pull request as it has been labeled with an integration ( |
Hey there @esphome/core, mind taking a look at this pull request as it has been labeled with an integration ( |
Hey there @sourabhjaiswal, mind taking a look at this pull request as it has been labeled with an integration ( |
Hey there @glmnet, @zuidwijk, mind taking a look at this pull request as it has been labeled with an integration ( |
Hey there @OttoWinter, mind taking a look at this pull request as it has been labeled with an integration ( |
Hey there @polyfaces, mind taking a look at this pull request as it has been labeled with an integration ( |
What does this implement/fix?
This PR removes the recently added
last_reset_type
and replaces all sensors that were usingstate_class: MEASUREMENT
+last_reset_type
withstate_class: TOTAL_INCREASING
.The resetting is now handled in home assistant automatically.
Breaking
This is a breaking change for any templates sensors, or sensors where users have added
last_reset_type
in YAML manually.This is also a breaking change for any custom components using
sensor.sensor_schema(...)
orsensor.SENSOR_SCHEMA
as thelast_reset_type
argument has been removed.Types of changes
Related issue or feature (if applicable): fixes
Pull request in esphome-docs with documentation (if applicable): esphome/esphome-docs#1442
Test Environment
Example entry for
config.yaml
:# Example config.yaml
Checklist:
tests/
folder).If user exposed functionality or configuration variables are added/changed: