1
0
mirror of https://github.com/home-assistant/core.git synced 2025-05-10 00:49:17 +00:00

745 Commits

Author SHA1 Message Date
Jan Bouwhuis
485c52568d
Fix error handling on subscribe when mqtt is not initialized () 2023-10-20 15:16:45 +02:00
Jan Bouwhuis
fe8fb8928c
Improve test creating mqtt certificate files ()
* Improve test creating mqtt certificate files

* Split tests

* Cleanup and de-duplicate

* Update tests/components/mqtt/test_util.py
2023-10-20 14:49:33 +02:00
Jan Bouwhuis
7d9014ae41
Do not fail MQTT setup if events or sensors configured via yaml can't be validated ()
* Add event and sensor

* Cleanup unused code

* Schema cannot be None for supported platform
2023-10-20 12:09:52 +02:00
Jan Bouwhuis
1efbba2631
Do not fail MQTT setup if covers configured via yaml can't be validated ()
Add cover
2023-10-20 10:51:42 +02:00
Jan Bouwhuis
12c4a10cfc
Do not fail MQTT setup if numbers configured via yaml can't be validated ()
Add number
2023-10-20 10:51:14 +02:00
Jan Bouwhuis
04fdcbe5fa
Do not fail MQTT setup if buttons configured via yaml can't be validated () 2023-10-20 08:13:59 +02:00
Jan Bouwhuis
f4e7c5aed3
Do not fail MQTT setup if humidifiers configured via yaml can't be validated ()
Add humidifier
2023-10-19 23:29:49 +02:00
Jan Bouwhuis
e26a2596af
Do not fail MQTT setup if climate's configured via yaml can't be validated ()
Add climate
2023-10-19 21:14:45 +02:00
Jan Bouwhuis
22c21fdc18
Do not fail MQTT setup if vacuum's configured via yaml can't be validated ()
Add vacuum
2023-10-19 20:11:09 +02:00
Jan Bouwhuis
5eb0a33795
Do not fail MQTT setup if text's configured via yaml can't be validated ()
Add text
2023-10-19 18:51:47 +02:00
Jan Bouwhuis
d0341c9754
Do not fail MQTT setup if images configured via yaml can't be validated ()
Add image
2023-10-19 18:50:02 +02:00
Jan Bouwhuis
3853214496
Do not fail MQTT setup if fans configured via yaml can't be validated ()
Add fan
2023-10-19 18:48:35 +02:00
Jan Bouwhuis
651b725cc0
Do not fail MQTT setup if binary sensors configured via yaml can't be validated ()
Add binary_sensor
2023-10-19 18:15:21 +02:00
Jan Bouwhuis
d149bffb07
Do not fail MQTT setup if lights configured via yaml can't be validated ()
* Add light

* Deduplicate code

* Follow up comment
2023-10-19 17:34:43 +02:00
Jan Bouwhuis
c377cf1ce0
Do not fail mqtt entry on single platform config schema error ()
* Do not fail mqtt entry on platform config

* Raise on reload with invalid config

* Do not store issues

* Follow up
2023-10-19 12:06:33 +02:00
Paul Bottein
c98c18f25e
Return 'None' for light attributes when off instead of removing them () 2023-10-19 01:08:08 +02:00
Robert Resch
f7292d5b00
Add check that sensors don't have EntityCategory.CONFIG set () 2023-10-09 13:37:52 +02:00
Jan Bouwhuis
db0c5bbbea
Fix mqtt sensor or binary_sensor state not saved after expiry ()
Fix mqtt sensor state not saved after expire
2023-10-08 20:57:14 +02:00
Jan Bouwhuis
74464fd94e
Ensure coverage mqtt entry disabled test () 2023-10-07 23:08:34 +02:00
Jan Bouwhuis
55bf309d2f
Add mqtt discovery schema error tests for all platforms ()
Add mqtt discovery schema error tests
2023-10-07 21:00:33 +02:00
Jan Bouwhuis
2bfb1e75d3
Correct device_class test for mqtt button () 2023-10-06 09:11:50 +02:00
Jan Bouwhuis
a3fe120457
Raise vol.Invalid for invalid mqtt device_tracker config ()
Raise vol.Invalid for invalid mqtt device_tracker
2023-10-04 19:36:34 +02:00
Jan Bouwhuis
0ded0ef4ee
Use dataclass instead of attr slots for mqtt PublishMessage and ReceiveMessage ()
Use dataclass instead of attr slots
2023-09-28 20:36:30 +02:00
Jan Bouwhuis
dc1d3f727b
Fix handling reload with invalid mqtt config ()
Fix handling reload whith invalid mqtt config
2023-09-27 20:59:19 -04:00
Jan Bouwhuis
0f38cd5794
Allow to reset an mqtt lock to an unknown state () 2023-09-27 09:50:01 +02:00
Jan Bouwhuis
20a2e129fb
Intialize mqtt lock in an unknown state in pessimistic mode ()
Intialize mqtt lock as unknown in pessimistic mode
2023-09-26 19:53:45 +02:00
Jan Bouwhuis
a4f7f3ba7e
Make sure time is changed in mqtt event test () 2023-09-26 00:32:12 +02:00
Jan Bouwhuis
60b8775f4a
Avoid redundant calls to async_write_ha_state in mqtt siren ()
* Avoid redundant calls to async_write_ha_state

* Add comment
2023-09-25 22:36:13 +02:00
Jan Bouwhuis
a242a1c107
Add tests for mqtt image ()
* Rework mqtt image writing state

* Revert mixin changes, add attr

* Revert code changes
2023-09-25 22:20:32 +02:00
Jan Bouwhuis
7258bc6457
Avoid redundant calls to async_write_ha_state in mqtt vacuum ()
* Avoid redundant calls to async_write_ha_state

* Add comment

* Rephrase
2023-09-25 22:17:29 +02:00
Jan Bouwhuis
ea1108503d
Rework and fix mqtt siren writing state and attributes ()
Rework mqtt siren writing state and attributes
2023-09-25 21:08:14 +02:00
Jan Bouwhuis
30c7e7fbdf
Avoid redundant calls to async_ha_write_state mqtt update platform ()
Avoid redundant calls to async_ha_write_state
2023-09-25 18:08:02 +02:00
Jan Bouwhuis
cd3d3b76a3
Avoid redundant calls to async_ha_write_state in mqtt text ()
Avoid redundant calls to async_ha_write_state
2023-09-25 18:07:24 +02:00
Jan Bouwhuis
8d10cdce4e
Avoid redundant calls to async_ha_write_state in mqtt switch ()
Avoid redundant calls to async_ha_write_state
2023-09-25 18:06:19 +02:00
Jan Bouwhuis
33d45b3454
Avoid redundant calls to async_write_ha_state in mqtt select ()
Avoid redundant calls to async_write_ha_state
2023-09-25 18:05:42 +02:00
Jan Bouwhuis
180f248370
Avoid redundant calls to async_write_ha_state in mqtt number ()
Avoid redundant calls to async_write_ha_state
2023-09-25 18:05:14 +02:00
Jan Bouwhuis
98cc2e8098
Avoid redundant calls to async_write_ha_state in mqtt lock ()
Avoid redundant calls to async_write_ha_state
2023-09-25 18:04:33 +02:00
Jan Bouwhuis
ce02cbefc9
Avoid redundant calls to async_write_ha_state in mqtt lawn_mower ()
Avoid redundant calls to async_write_ha_state
2023-09-25 18:03:52 +02:00
Jan Bouwhuis
002be37257
Rework and added tests for mqtt event ()
Use write_state_on_attr_change and add tests
2023-09-25 18:02:17 +02:00
Jan Bouwhuis
f83a597603
Avoid redundant calls to async_write_ha_state in mqtt humidifier ()
Avoid redundant calls to async_write_ha_state
2023-09-25 18:00:08 +02:00
Jan Bouwhuis
3da4815522
Avoid redundant calls to async_write_ha_state for mqtt fan ()
Avoid redundant calls to async_write_ha_state
2023-09-25 17:59:33 +02:00
Jan Bouwhuis
edb28be964
Avoid redundant calls to async_write_ha_state in mqtt device_tracker ()
Avoid redundant calls to async_ha_write_state
2023-09-24 12:52:13 +02:00
Jan Bouwhuis
c6d62faff3
Avoid redundant calls to async_write_ha_state in mqtt cover ()
Avoid redundant calls to async_write_ha_state
2023-09-22 22:47:07 +02:00
Jan Bouwhuis
5b422daf36
Avoid redundant calls to async_write_ha_state in MQTT light ()
* Limit state writes for mqtt light

* Additional tests and review follow up
2023-09-22 13:32:30 +02:00
Jan Bouwhuis
87ae5add8a
Fix mqtt light rgbww update without state topic ()
* Fix mqtt light rgbww update without state topic

* Add @callback decprator and correct mired conv
2023-09-22 13:31:29 +02:00
Jan Bouwhuis
a66ad39c4e
Assign color_mode for mqtt light as ColorMode () 2023-09-22 12:09:37 +02:00
Jan Bouwhuis
384adb1c87
Avoid redundant calls to async_write_ha_state in MQTT climate & water_heater ()
Limit state writes for mqtt climate & water_heater
2023-09-22 11:22:57 +02:00
Jan Bouwhuis
1041610a70
Avoid redundant calls to async_write_ha_state in MQTT mqtt alarm_control_panel ()
Limit state writes for mqtt alarm_control_panel
2023-09-22 11:22:09 +02:00
Jan Bouwhuis
aed3ba3acd
Avoid redundant calls to async_ha_write_state in MQTT (binary) sensor ()
* Only call `async_ha_write_state` on changes.

* Make helper class

* Use UndefinedType

* Remove del

* Integrate monitor into MqttEntity

* Track extra state attributes and availability

* Add `__slots__`

* Add monitor to MqttAttributes and MqttAvailability

* Write out loop

* Add test

* Make common test and parameterize

* Add test for last_reset attribute

* MqttMonitorEntity base class

* Rename attr and update docstr `track` method.

* correction doct

* Implement as a decorator

* Move tracking functions into decorator

* Rename decorator

* Follow up comment
2023-09-21 13:33:26 +02:00
Jan Bouwhuis
6b265120b3
Fix entity name attribute on mqtt entity is not removed on update ()
Fix entity name attribute is not remove on update
2023-09-12 15:22:37 +02:00