mirror of
https://github.com/home-assistant/home-assistant.io.git
synced 2025-07-19 07:17:14 +00:00
Automation troubleshooting: rename service to action (#33762)
This commit is contained in:
parent
a6cb5bbd95
commit
dd2c41ae7c
@ -13,7 +13,7 @@ Many automations can be tested directly in the automation editor UI.
|
||||
|
||||
In the three dots menu in the automation list or automation editor UI, select the **Run** button. This will execute all of the {% term actions %}, while skipping all {% term triggers %} and {% term conditions %}. This lets you test the full sequence of actions, as if the automation was triggered and all conditions were true. Note that any [trigger ID](/docs/automation/trigger/#trigger-id) used in your triggers will not be active when you test this way. The Trigger ID or any data passed by in the `trigger` data in conditions or actions can't be tested directly this way.
|
||||
|
||||
You can also trigger an automation manually. This can test the conditions as if the automation was triggered by an event. Navigate to {% my developer_services title="**Developer tools** > **Services**" %}. In the service selection drop-down, select **Automation: Trigger**, then **Choose entity** to select the automation you are testing. Toggle whether to skip the conditions, then **Call service**. If needed, additional `trigger` or other data can be added in the YAML view for testing. The [trigger](/docs/automation/trigger/) page has more information about data within the trigger.
|
||||
You can also trigger an automation manually. This can test the conditions as if the automation was triggered by an event. Navigate to {% my developer_services title="**Developer tools** > **Actions**" %}. In the **Action** drop-down, select **Automation: Trigger**, then **Choose entity** to select the automation you are testing. Toggle whether to skip the conditions, then **Perform action**. If needed, additional `trigger` or other data can be added in the YAML view for testing. The [trigger](/docs/automation/trigger/) page has more information about data within the trigger.
|
||||
|
||||
Testing with complex triggers, conditions, and variables can be difficult. Note that using the **Run** button will skip all triggers and conditions, while **Developer Tools** can be used with or without checking conditions.
|
||||
|
||||
@ -25,7 +25,7 @@ In the automation editor UI, each {% term condition %} and {% term action %} can
|
||||
|
||||
- Testing an action block will run that block immediately.
|
||||
|
||||
Note that complex automations that depend on previous blocks, such as trigger IDs, variables in templates, or service calls that return data to use in subsequent blocks, cannot be tested this way.
|
||||
Note that complex automations that depend on previous blocks, such as trigger IDs, variables in templates, or action calls that return data to use in subsequent blocks, cannot be tested this way.
|
||||
|
||||
If you are writing automations in YAML, it is also useful to go to {% my server_controls title="**Developer tools** > **YAML**" %}** and in the Configuration validation section, select the **Check configuration** button. This is to make sure there are no syntax errors before restarting Home Assistant. In order for **Check configuration** to be visible, you must enable **Advanced Mode** on {% my profile title="your user profile" %}.
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user