fix(sre): separate controlled run outcomes
This commit is contained in:
@@ -130,7 +130,17 @@ _RUN_SUMMARY_SQL = text(
|
||||
count(*) FILTER (WHERE state = 'completed')::int AS completed_runs,
|
||||
count(*) FILTER (
|
||||
WHERE state IN ('failed', 'cancelled', 'timeout')
|
||||
)::int AS failed_runs
|
||||
)::int AS failed_runs,
|
||||
count(*) FILTER (
|
||||
WHERE is_shadow IS FALSE
|
||||
AND step_count > 0
|
||||
AND state = 'completed'
|
||||
)::int AS controlled_completed_runs,
|
||||
count(*) FILTER (
|
||||
WHERE is_shadow IS FALSE
|
||||
AND step_count > 0
|
||||
AND state IN ('failed', 'cancelled', 'timeout')
|
||||
)::int AS controlled_failed_runs
|
||||
FROM awooop_run_state
|
||||
WHERE project_id = :project_id
|
||||
AND created_at >= :window_start
|
||||
@@ -335,6 +345,8 @@ def build_automation_slo_scorecard(
|
||||
"controlled_runs_with_steps",
|
||||
"completed_runs",
|
||||
"failed_runs",
|
||||
"controlled_completed_runs",
|
||||
"controlled_failed_runs",
|
||||
)
|
||||
}
|
||||
return {
|
||||
|
||||
Reference in New Issue
Block a user