-
-
Notifications
You must be signed in to change notification settings - Fork 30k
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
Aqara restore door sensor state on start #65128
Aqara restore door sensor state on start #65128
Conversation
Hey there @Danielhiversen, @syssi, mind taking a look at this pull request as it has been labeled with an integration ( |
Ready for revieuw/merge. |
I hit this problem after updating to 2022.02.0b0 and 2022.02.0b1 - my Aquara door/windows and leak sensors after restart goes to 'unknown' state until any action with that sensors which triggers state change. On Xiaomi Home state is correct. |
@piio the latest commit schould also fix Natgas, WaterLeak and Smoke sensors. |
@starkillerOG Hi, I just checked - my water leak sensor is no more in 'unknown' state, it shows last sensor state. |
@MartinHjelmare could you add this to the 2022.02 milestone? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good!
Breaking change
Proposed change
On HA 2022.02 dev the aqara door sensors will start with state "unknown" instead of the last known state before the HomeAsstant restart as it was before.
For Door/Window sensors it makes sence to just restore the last known state.
Especially if it consernes window sensors that for instance will not be opend during the winter, the state will stay on unknown the whole winter, which is not desireable.
Type of change
Additional information
Checklist
black --fast homeassistant tests
)If user exposed functionality or configuration variables are added/changed:
If the code communicates with devices, web services, or third-party tools:
Updated and included derived files by running:
python3 -m script.hassfest
.requirements_all.txt
.Updated by running
python3 -m script.gen_requirements_all
..coveragerc
.The integration reached or maintains the following Integration Quality Scale:
To help with the load of incoming pull requests: