Claude Sonnet 5.5 · Heavy

notification-rule-processing-engine-grafana-codex

Grafana · Go · L · 300–799 lines · 6 files

The generalist plus 9 specialist lens agents in parallel, then the same verify and dedup steps. Judge: Claude Haiku 5.5.

Gold bugs found
1 of 4
Comments published
2
Comments matching a bug
1
Comments not matching
1
Cost of this PR
$2.566

Published comments (2)

mediumbugpublic/app/features/alerting/unified/hooks/useAbilities.ts:301-326

Grafana recording rules lose Export, Pause and Restore abilities — Grafana recording rules are Grafana-managed but not alerting rules, so `isAlertingRule` strips their Export and Pause abilities in the list view, unlike the ruler-based hook. Use `prometheusRuleType.grafana.rule(rule)` for `ModifyExport`, `Pause` and `Restore`, and keep `isAlertingRule` only for `Silence`.

mediumbugpublic/app/features/alerting/unified/hooks/useAbilities.ts:308-318

Duplicate ability enabled when rule is undefined (skipToken) for Grafana prom rules — With an undefined `rule` (the `skipToken` case), `Duplicate` stays enabled, and `AlertRuleMenu` ORs it with the ruler ability, so cloud and Mimir rules get a Duplicate item even when unsupported. Set `MaybeSupported` to `NotSupported` when `rule` is undefined. **Also found in:** - `public/app/features/alerting/unified/components/rule-viewer/AlertRuleMenu.tsx:89-92`

Gold bugs found (1)

mediumWhen the Grafana prom-rule branch is skipped (datasource rules), useAllGrafanaPromRuleAbilities(undefined) still reports Duplicate as supported and allowed by Grafana create permission, and AlertRuleMenu ORs it with the ruler ability, so Duplicate appears on cloud rules even when the ruler check denies it.

Gold bugs missed (3)

highThe pause menu item is still gated on a Grafana ruler rule, but the list view now passes only the Prometheus rule, so Pause/Resume disappears for list-view rules even when the user may pause them.
highThe Delete menu item still requires a ruler rule, which list-view Grafana rules no longer provide, so users with delete permission lose the Delete action.
highFor list-view Grafana rules RuleActionsButtons gets only promRule, so the Silence menu item is shown but the silence drawer, still gated on a ruler alerting rule, never renders and clicking Silence does nothing.