mirror of
https://github.com/home-assistant/frontend.git
synced 2025-07-23 09:16:38 +00:00
Fix failed conditions reason (#8870)
This commit is contained in:
parent
7c823c98ae
commit
d7c0c2ea72
@ -17,7 +17,7 @@ import { DemoTrace } from "../data/traces/types";
|
|||||||
const traces: DemoTrace[] = [
|
const traces: DemoTrace[] = [
|
||||||
mockDemoTrace({ state: "running" }),
|
mockDemoTrace({ state: "running" }),
|
||||||
mockDemoTrace({ state: "debugged" }),
|
mockDemoTrace({ state: "debugged" }),
|
||||||
mockDemoTrace({ state: "stopped", script_execution: "failed_condition" }),
|
mockDemoTrace({ state: "stopped", script_execution: "failed_conditions" }),
|
||||||
mockDemoTrace({ state: "stopped", script_execution: "failed_single" }),
|
mockDemoTrace({ state: "stopped", script_execution: "failed_single" }),
|
||||||
mockDemoTrace({ state: "stopped", script_execution: "failed_max_runs" }),
|
mockDemoTrace({ state: "stopped", script_execution: "failed_max_runs" }),
|
||||||
mockDemoTrace({ state: "stopped", script_execution: "finished" }),
|
mockDemoTrace({ state: "stopped", script_execution: "finished" }),
|
||||||
|
@ -475,7 +475,7 @@ export class HaAutomationTracer extends LitElement {
|
|||||||
let extra: TemplateResult | undefined;
|
let extra: TemplateResult | undefined;
|
||||||
|
|
||||||
switch (this.trace.script_execution) {
|
switch (this.trace.script_execution) {
|
||||||
case "failed_condition":
|
case "failed_conditions":
|
||||||
reason = "a condition failed";
|
reason = "a condition failed";
|
||||||
break;
|
break;
|
||||||
case "failed_single":
|
case "failed_single":
|
||||||
|
@ -66,7 +66,7 @@ export interface AutomationTrace {
|
|||||||
};
|
};
|
||||||
script_execution:
|
script_execution:
|
||||||
| // The script was not executed because the automation's condition failed
|
| // The script was not executed because the automation's condition failed
|
||||||
"failed_condition"
|
"failed_conditions"
|
||||||
// The script was not executed because the run mode is single
|
// The script was not executed because the run mode is single
|
||||||
| "failed_single"
|
| "failed_single"
|
||||||
// The script was not executed because max parallel runs would be exceeded
|
// The script was not executed because max parallel runs would be exceeded
|
||||||
@ -80,8 +80,7 @@ export interface AutomationTrace {
|
|||||||
| "error"
|
| "error"
|
||||||
// The exception is in the trace itself or in the last element of the trace
|
// The exception is in the trace itself or in the last element of the trace
|
||||||
// Script execution stopped by async_stop called on the script run because home assistant is shutting down, script mode is SCRIPT_MODE_RESTART etc:
|
// Script execution stopped by async_stop called on the script run because home assistant is shutting down, script mode is SCRIPT_MODE_RESTART etc:
|
||||||
| "cancelled"
|
| "cancelled";
|
||||||
| string;
|
|
||||||
// Automation only, should become it's own type when we support script in frontend
|
// Automation only, should become it's own type when we support script in frontend
|
||||||
trigger: string;
|
trigger: string;
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user