Skip to content

feat: full attribute filters on metrics widgets, create_dashboard where/unit/series count - #1388

Merged
Makisuo merged 6 commits into
mainfrom
feat/dashboard-metric-attr-filters
Oct 12, 2026
Merged

Makisuo merged 6 commits into
mainfrom
feat/dashboard-metric-attr-filters

fix: quote service_name in widget where clauses, skip missing labels …

b4ebf3c
Select commit
Loading
Failed to load commit list.
Maple Review Bot / Maple / review succeeded Oct 12, 2026 in 4m 43s

Confidence 9/10 · No issues found

🟢 Confidence 9/10 · safe to merge
Both follow-up fixes (quoteWhereValue, numeric present guard) are correct, pinned by tests, and reach no other caller.
quality 100/100 · no findings · tests covered · risk medium

Adds full attr.* operator support to metric datapoint filters end to end, plus where/unit on create_dashboard simple widgets and a seriesCount in widget validation. The follow-up fixes at this head are correct; safe to merge.

  • buildAttrFilterCondition requires a non-empty label for attr.x < / <= / > />=
  • create_dashboard service_name goes through quoteWhereValue in the widget where clause
  • Metrics queries and the runtime take the whole attributeFilters list
  • WidgetInspectionEntry reports seriesCount from the largest query
What was checked
  • quoteWhereValue always quotes, and splitOnKeyword/unquote are quote-aware, so " in a service name cannot open a clause (where-clause.ts:96, 132)
  • present only drops missing/empty labels; gt 0 and equals behaviour is unchanged
  • OR-group members still compare against the empty accumulator, so metricName cannot make setsOtherField true

b4ebf3c · Updated on every push. Reply "won't fix" to dismiss a finding, or mention @maple-review-bot to ask about one.