You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
datadog-cr-validate: catch dashboard queries that break when a template variable is set to * #158
The dashboard lint in actions/datadog-cr-validate/validate.py (dashboards()) checks only that spec.widgets is a JSON array, that every widget has a definition.type, and that every $variable is declared. It does not fill in template variables or parse the queries that result. The tag check (metric_filters) skips any filter that contains * or $.
Why it matters
DND-IT/launchpad's App Overview dashboard filtered on gateway.k8s.aws.alb/resource:*$namespace.value*. With the variable set to * (the default, or the built-in All entry), the filter became ***. Datadog rejects that query (Rule 'or_op' didn't match at '**}'), so every ALB widget showed no data, and the lint passed it.
Suggested fix
Lint: flag a template variable wrapped in wildcards (*$var.value*, *$var*), because selecting * always yields ***.
And/or: fill in each variable's defaults plus *, then run each metric query through POST /api/v1/query (or the scalar/timeseries query API) and fail on parse errors.
Activity