J. Nick Koston
1381b279f0
Update template sensor to use async_track_template_result ( #38940 )
...
* Add template entity
* Update template tracking to work for template sensors
* add test for whitespace
* Update homeassistant/helpers/config_validation.py
* revert
* fix
* reduce
* fix _refresh missing decorator
* defer until start
* do not throw errors during startup
* defer tracking until start event
Co-authored-by: Swamp-Ig <github@ninjateaparty.com>
2020-08-20 08:06:41 -05:00
Franck Nijhof
bdc5af8dd2
Add support for attributes in (numeric) state conditions ( #39050 )
2020-08-19 20:01:27 +02:00
Phil Bruckner
ca9dd0c833
Reorganize trigger code ( #38655 )
2020-08-17 11:54:56 -05:00
Phil Bruckner
580e229cf2
Create variable with result of wait_template and accept template for timeout option ( #38634 )
2020-08-12 13:42:06 -05:00
Phil Bruckner
726d5fdd94
Allow float values in time periods ( #38023 )
2020-07-21 19:41:42 -05:00
Phil Bruckner
7e280e2b27
Add choose script action ( #37818 )
...
Co-authored-by: Paulus Schoutsen <balloob@gmail.com>
2020-07-14 10:22:54 -07:00
Phil Bruckner
91271f388c
Add new repeat loop for scripts and automations ( #37589 )
2020-07-10 13:37:19 -05:00
Franck Nijhof
02f174e2e6
Add support for multiple states/zones in conditions ( #36835 )
...
Co-authored-by: Paulus Schoutsen <balloob@gmail.com>
2020-06-16 00:53:13 +02:00
Franck Nijhof
ba73ac12ba
Add support for multiple entity_ids in conditions ( #36817 )
2020-06-15 22:54:19 +02:00
Ville Skyttä
29b8f76e57
Use past tense in messages for already invalidated deprecated configs ( #36591 )
2020-06-09 23:26:55 -07:00
Franck Nijhof
e86bedb223
Prevent possible secret values to show up in deprecation logs ( #36368 )
...
Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2020-06-02 17:29:59 +02:00
Bram Kragten
cb7b8d94c0
Add check for HTML in translations ( #35615 )
...
* Add check for HTML in translations
and remove existing html
* Add test
2020-05-14 19:33:14 +02:00
Franck Nijhof
c93c6a66e8
Add NOT condition helper ( #34624 )
2020-04-24 09:40:23 -07:00
Ville Skyttä
221d5205e4
Upgrade mypy to 0.770, tighten config a bit ( #32715 )
...
* Upgrade mypy to 0.770, related cleanups
https://mypy-lang.blogspot.com/2020/03/mypy-0770-released.html
* Clean up config and make it a notch stricter, address findings
2020-03-12 11:52:20 +01:00
Paulus Schoutsen
6a21afa2a8
Improve script validation ( #32461 )
2020-03-05 11:44:42 -08:00
Paulus Schoutsen
536b31305a
Support multiple Lovelace dashboards ( #32134 )
...
* Support multiple Lovelace dashboards
* Mark collection maintenance as unfinished
* Fix import
* Add websockets commands for resource management
* Revert "Add websockets commands for resource management"
This reverts commit 7d140b2bcc
.
Co-authored-by: Bram Kragten <mail@bramkragten.nl>
2020-02-25 11:18:21 -08:00
Paulus Schoutsen
ca01e9a537
Improve condition validation error msg ( #32135 )
2020-02-24 09:59:34 +01:00
Robert Svensson
043d36f7c6
Change multi_select config validator to class ( #31828 )
...
* Move multi_select to class
* Fix serializer and add test
* Serializer should also return options
2020-02-14 11:09:40 -08:00
Robert Svensson
6211a2bb98
Add multi select support to config validation and to custom serializer ( #31798 )
2020-02-13 13:12:09 -08:00
Paulus Schoutsen
f41623ca64
Log warning when entities referenced in service call not found ( #31427 )
...
* Raise entities not found error
* Make it a warning, not an error
* Add support for MATCH_ENTITY_NONE
* Fix lint
* Fix tests
2020-02-04 14:42:07 -08:00
Paulus Schoutsen
7687ac8b91
Fix service annotations ( #31402 )
...
* Fix service annotations
* Filter area_id from service data
* Fix services not accepting entities
* Typo
2020-02-02 15:36:39 -08:00
Ville Skyttä
fa4fa30461
Various string cleanups ( #30435 )
...
* Remove some unnecessary string concatenations
* Replace some simple str.formats with f-strings
* Replace some string concatenations with f-strings
2020-01-03 14:47:06 +01:00
Ville Skyttä
e6388e186c
Remove unnecessary string literal concatenations ( #30360 )
2020-01-02 21:17:10 +02:00
Ville Skyttä
868eb3c735
More helpers type improvements ( #30145 )
2019-12-22 19:51:39 +01:00
Ville Skyttä
ecdc1adf90
Upgrade mypy to 0.761 ( #30104 )
...
https://mypy-lang.blogspot.com/2019/12/mypy-0760-released.html
https://github.com/python/mypy/releases/tag/v0.761
2019-12-20 22:35:02 +01:00
Bas Nijholt
67c56c860d
Sort imports according to PEP8 for 'homeassistant' folder ( #29789 )
...
Components are already done
2019-12-09 16:42:10 +01:00
Paulus Schoutsen
eef91f843d
Rendering complex template objects to leave non-template values alone ( #29353 )
2019-12-03 14:15:45 -08:00
Paulus Schoutsen
02d9ed5e36
Do not select all entities when omitting entity ID in service call ( #29178 )
...
* Do not select all entities when omitting entity ID
* Address comments Matthew
* Require either area_id or entity_id
* Fix tests
* Fix test
2019-12-02 16:23:12 -08:00
Erik Montnemery
42691b783e
Handle empty service in script action gracefully ( #27467 )
...
* Handle empty service in script action gracefully
* Add test
2019-10-12 12:28:47 -07:00
Matthew Donoughe
d16edb3ef0
add script shortcut for activating scenes ( #27223 )
...
* add script shortcut for activating scenes
use `- scene: scene.<scene name>` in a script to activate a scene
* Update validation
2019-10-05 13:30:43 -07:00
Franck Nijhof
2e17ad86af
Adds guards for missing information in call stack frames ( #27217 )
2019-10-05 11:59:33 +02:00
Erik Montnemery
65ce3b49c1
Add support for `for` to binary_sensor, light and switch device triggers ( #26658 )
...
* Add support for `for` to binary_sensor, light and switch device triggers
* Add WS API device_automation/trigger/capabilities
2019-10-02 22:14:52 +02:00
Ville Skyttä
fde128d66c
Upgrade mypy to 0.730, address raised issues ( #26959 )
...
https://mypy-lang.blogspot.com/2019/09/mypy-730-released.html
2019-09-27 22:57:59 +03:00
Erik Montnemery
e57e7e8449
Improve validation of device trigger config ( #26910 )
...
* Improve validation of device trigger config
* Remove action and condition checks
* Move config validation to own file
* Fix tests
* Fixes
* Fixes
* Small tweak
2019-09-27 17:48:48 +02:00
Paulus Schoutsen
6fdff9ffab
Reorg device automation ( #26880 )
...
* async_trigger -> async_attach_trigger
* Reorg device automations
* Update docstrings
* Fix types
* Fix extending schemas
2019-09-24 14:57:05 -07:00
Ville Skyttä
54242cd65c
Type hint additions ( #26765 )
2019-09-20 08:23:34 -07:00
Erik Montnemery
02ded7a4a8
Remove device from device action schema ( #26536 )
2019-09-09 10:40:22 -07:00
Erik Montnemery
b1c2a5fa08
Add device automation action ( #26455 )
...
* Add support for device actions, with light as example.
* Add translation; return list
2019-09-05 16:26:22 -07:00
Erik Montnemery
f7dc537275
Add device automation condition ( #26313 )
...
* Add support for device conditions
* Lint
* Update test case
* Make and+or conditions async, adjust tests
* Cleanup tests
* Remove non callback versions of conditions, correct typing
* Correct typing
* Update light/strings.json
* Address review comments
* Make device automation lists simple lists, not dicts
* Add device_automation/const.py
* Use IS_ON/IS_OFF everywhere for conditions
2019-09-05 16:49:32 +02:00
Franck Nijhof
2f0eb07624
Migrate legacy typehints in core to PEP-526 ( #26403 )
...
* Migrate legacy typehints in core to PEP-526
* Fix one type
2019-09-03 20:36:04 -07:00
Johann Kellerman
8b9d0593b1
Allow components with empty list config (i.e. person) in packages ( #25827 )
...
* Fix #23424
* mypy Lists
2019-08-10 16:30:33 -07:00
Ville Skyttä
a54ade1189
Spelling fixes ( #25666 )
2019-08-02 23:20:06 +02:00
Paulus Schoutsen
4de97abc3a
Black
2019-07-31 12:25:30 -07:00
Ville Skyttä
d64f1e767c
Type check all helpers ( #25373 )
...
* Type check all helpers, add inline exclusions for work in progress
* Remove unused Script._template_cache
* Add some missing type hints
* Remove unneeded type: ignore
* Type hint fixes
* Mypy assistance tweaks
* Don't look for None in deprecated config "at most once" check
* Avoid None name slugify attempt when generating entity id
* Avoid None state store attempt on entity remove
2019-07-21 09:59:02 -07:00
Paulus Schoutsen
7aae490a85
Allow area ID in service call schemas ( #25121 )
...
* Allow area ID in service call schemas
* Remove ATTR_ENTITY_ID from service light turn off schcema
2019-07-15 11:31:53 -07:00
Paulus Schoutsen
27d750db1c
Guard module being None ( #25077 )
2019-07-11 09:38:58 +02:00
Penny Wood
b30f4b8fc0
Improve boolean validator ( #24294 )
...
* Improve boolean validator
* Remove extra throw
* Remove None test as discussed
* Fix for tests depending on None == False
2019-06-07 22:18:02 -07:00
Paulus Schoutsen
59ce31f44f
No longer allow invalid slugs or extra keys ( #24176 )
...
* No longer allow slugs
* Lint
* Remove HASchema
* Lint
* Fix tests
2019-05-30 13:33:26 +02:00
Penny Wood
5b9d01139d
render_with_collect method for template ( #23283 )
...
* Make entity_filter be a modifiable builder
* Add render_with_collect method
* Use sync render_with_collect and non-class based test case
* Refactor: Template renders to RenderInfo
* Freeze with exception too
* Finish merging test changes
* Removed unused sync interface
* Final bits of the diff
2019-05-01 10:54:25 +08:00
Erik Montnemery
8d775caaac
Always print invalid configuration data ( #21972 )
...
* Always print invalide configuration data
* Print offending data as yaml
* Revert "Print offending data as yaml"
This reverts commit 01721a21a9ff918ed2c8595151ebfe55eb2f7d36.
* Do not print sensitive data
* Print MQTT topic
* Add line break
* Review comments
* review comments
2019-04-29 13:45:53 -07:00