Franck Nijhof
3d557b5583
Collection of code styling tweaks ( #87381 )
2023-02-04 12:52:26 -05:00
epenet
62482f3500
Improve typing in script integration ( #87076 )
2023-02-02 16:31:46 -05:00
Franck Nijhof
5e81d28116
Update black to 23.1.0 ( #87188 )
2023-02-02 18:35:24 +01:00
Erik Montnemery
53637d486d
Improve error message when a script fails to validate ( #84438 )
2022-12-22 16:26:57 +01:00
Erik Montnemery
f7694c0550
Only reload modified scripts ( #80470 )
...
Co-authored-by: Franck Nijhof <git@frenck.dev>
2022-10-24 20:47:06 +02:00
Erik Montnemery
627bd82766
Simplify parsing of script and automation config ( #80465 )
2022-10-17 11:42:17 +02:00
Erik Montnemery
4ebf9df901
Unconditionally call DomainBlueprints.populate ( #80336 )
2022-10-14 12:03:43 -04:00
Erik Montnemery
284893d942
Fix reload of automation and scripts when blueprint changed ( #80322 )
2022-10-14 16:43:09 +02:00
Erik Montnemery
7f08dd851e
Make script entities register their own service ( #79202 )
2022-09-28 11:05:29 -04:00
Paulus Schoutsen
d3f5ccfed8
Allow fetching script config ( #79131 )
2022-09-28 13:52:58 +02:00
Erik Montnemery
6ef33b1d39
Fix overriding a script's entity_id ( #78765 )
2022-09-28 10:37:34 +02:00
epenet
b4afb1cb6b
Make use of generic EntityComponent ( #78492 )
2022-09-15 11:53:00 +02:00
Erik Montnemery
30702bdcd2
Deduplicate some code in scripts and automations ( #78443 )
2022-09-15 07:41:11 +02:00
epenet
996bcbdac6
Make EntityComponent generic ( #78473 )
2022-09-14 14:16:23 -04:00
Erik Montnemery
2ba0f42acc
Prevent deleting blueprints which are in use ( #78444 )
2022-09-14 16:47:08 +02:00
Erik Montnemery
1df99badcf
Allow scripts to turn themselves on ( #71289 )
2022-05-04 15:54:37 +02:00
Franck Nijhof
d08b751a85
Add unique ID to scripts ( #70345 )
2022-04-21 20:04:02 +02:00
J. Nick Koston
c3108b3899
Exclude attributes for automation and script domains ( #70168 )
2022-04-18 12:10:18 +02:00
Joakim Plate
251691f5b7
Make sure blueprint cache is flushed on script reload ( #67899 )
2022-03-09 11:21:31 -08:00
epenet
5f0fcb1a70
Add setup type hints to script ( #64030 )
...
Co-authored-by: epenet <epenet@users.noreply.github.com>
2022-01-13 14:24:58 +01:00
Marc Mueller
fa7e787415
Update typing (3) [k-t] ( #63924 )
2022-01-11 21:26:55 +01:00
epenet
92ace6c2e8
Ensure service calls are typed [s-u] ( #62922 )
...
Co-authored-by: epenet <epenet@users.noreply.github.com>
2021-12-28 14:23:42 +01:00
Marc Mueller
7063c05127
Use assignment expressions 33 ( #58717 )
2021-10-30 16:32:41 +02:00
Marc Mueller
b1d49b3b66
Use assignment expressions 29 ( #58713 )
2021-10-30 16:31:43 +02:00
Marc Mueller
62c20860ac
Use assignment expressions 22 ( #57971 )
2021-10-21 08:33:10 +02:00
Franck Nijhof
2cdaf632a4
Restore last_triggered state in scripts ( #55071 )
2021-08-23 11:05:29 -07:00
Richard T. Schaefer
9e219d9b6e
Add this variable for use by automation and script templates ( #52774 )
2021-07-28 09:09:13 +02:00
Franck Nijhof
89e7983ee0
Add Blueprint foundation to Scripts ( #48621 )
...
Co-authored-by: Paulus Schoutsen <balloob@gmail.com>
2021-04-27 15:15:38 -07:00
Erik Montnemery
ce64690817
Make number of stored traces configurable ( #49728 )
2021-04-27 10:27:12 -07:00
Philip Allgaier
6fe04f40a2
Ensure HA script and Python script services have a name ( #47204 )
...
Co-authored-by: Franck Nijhof <git@frenck.dev>
2021-03-31 15:09:45 +02:00
Bram Kragten
d1a1e70726
Search for areas used in automations and scripts ( #48499 )
...
Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
Co-authored-by: Bram Kragten <mail@bramkragten.nl>
Co-authored-by: Paulus Schoutsen <balloob@gmail.com>
2021-03-30 15:01:56 -07:00
Erik Montnemery
7534b54e4e
Merge condition and action traces ( #48461 )
2021-03-29 14:06:49 -07:00
Franck Nijhof
81ae0ee451
Add support for Selectors in Script service fields ( #48469 )
2021-03-29 18:05:45 +02:00
Erik Montnemery
8896ae0d56
Add support for tracing script execution ( #48276 )
...
* Add support for tracing script execution
* Tweak
2021-03-24 17:56:22 +01:00
Erik Montnemery
346a724ac3
Mark base components' state_attribute @final, rename others to extra_state_attributes ( #48161 )
...
* Mark base state_attributes @final, rename others to extra_state_attributes
* Fix calendar, update tests
2021-03-21 10:38:24 +01:00
Marc Mueller
a3cd1854f6
Update typing 12 ( #48073 )
2021-03-18 14:31:38 +01:00
tkdrob
3baeed3684
Clean up constants ( #47323 )
2021-03-05 19:08:04 +01:00
Erik Montnemery
17401cbc29
Initial automation tracing ( #46755 )
...
* Initial prototype of automation tracing
* Small fixes
* Lint
* Move trace helpers to its own file
* Improve trace for state and numeric_state conditions
* Tweaks + apply suggestions from code review
* Index traces by automation_id, trace while script is running
* Refactor condition tracing
* Improve WS API to get traces for single automation
* Add tests
* Fix imports
* Fix imports
* Address review comments
* Cap logging of loops
* Remove unused ContextVar action_config
2021-03-04 14:16:24 +01:00
Anders Melchiorsen
9f4874bb81
Explicitly create_task for asyncio.wait ( #46325 )
2021-02-20 19:57:46 +01:00
Paulus Schoutsen
5117a16841
Extract variable rendering ( #39934 )
2020-09-11 12:24:16 +02:00
Paulus Schoutsen
aa9dff572e
Add default variables to script helper ( #39895 )
2020-09-10 20:41:42 +02:00
Phil Bruckner
4486251382
Add max_exceeded log level option to automations & scripts ( #39448 )
2020-09-02 11:05:14 +02:00
Phil Bruckner
716fa63e73
Update script helper constructor parameters ( #38763 )
...
Add domain and make it and name required.
Add optional running_description.
2020-08-12 11:39:05 -05:00
Phil Bruckner
9e12e3f96c
Allow automation to be turned off without stopping actions ( #38436 )
2020-08-01 21:31:47 -05:00
Bram Kragten
7d77fa92c2
Add mode info attributes to script and automation ( #37815 )
...
Co-authored-by: J. Nick Koston <nick@koston.org>
2020-07-14 10:47:59 -07:00
Phil Bruckner
63e55bff52
Remove legacy script mode and simplify remaining modes ( #37729 )
2020-07-10 17:00:57 -07:00
Phil Bruckner
91271f388c
Add new repeat loop for scripts and automations ( #37589 )
2020-07-10 13:37:19 -05:00
Franck Nijhof
53545c984b
Log lines do not end with a full stop ( #37527 )
2020-07-05 23:04:19 +02:00
Phil Bruckner
f7c4900d5c
Enhance automation integration to use new features in script helper ( #37479 )
2020-07-05 09:25:15 -05:00
Phil Bruckner
38210ebbc6
Enhance script integration to use new features in script helper ( #37201 )
2020-06-30 10:22:26 -07:00