Commit graph

7 commits

Author SHA1 Message Date
Ville Skyttä
843789528e Remove extra quotes from docstrings (#14431) 2018-05-13 11:06:15 +02:00
blackwind
ec3ce4c80d Publish attributes unconditionally (#14179)
* Publish attributes unconditionally

Because the attribute publish command was previously hidden behind `if val:`, falsy values like False and 0.0 weren't being published, thereby making Statestream -- particularly in the case of booleans, where the first True would be retained indefinitely -- a completely worthless indicator of state.

* Change bool test to False to confirm falsy values pass
2018-05-05 09:31:39 -04:00
Matt White
148a7ddda9 Add include/exclude filter to mqtt_statestream (#10354)
* Add publish filter to mqtt_statestream

* Add tests for include/excludes in mqtt_statestream
2017-11-08 15:54:12 +01:00
Lukas Barth
248d974ded Cast attribute values to string before publishing to MQTT (#9872)
* Cast attribute values to string before publishing to MQTT

* Simplify

* Use JSON serialization, add test
2017-10-27 08:55:04 -07:00
Matt White
755a2a8291 mqtt_statestream: Add options to publish attributes/timestamps (#9645) 2017-10-02 17:41:07 +02:00
Matt White
04bed51277 mqtt_statestream: Update to append 'state' to topic for future use with mqtt discovery (#9446) 2017-09-15 23:05:58 -07:00
Matt White
31f189da82 Added mqtt_statestream component (#9286)
* Added mqtt_statestream component

* Added tests for mqtt_statestream component

* mqtt_statestream: add test for valid new_state

* mqtt_statestream: Don't set initialized state

* mqtt_statestream: Switch to using async_track_state_change

* Cleanup
2017-09-11 22:08:12 +02:00