feat(reporter): support {value} substitution in rule messages #85

Closed
opened 2026-05-26 19:00:44 +02:00 by michael · 0 comments
Owner

Goal

The reporter currently only substitutes {file}, {line}, and {count} in
rule messages. Primitives like listvalues produce per-value findings that
need {value} substituted to show the offending value in the output.

Example

Current output:
init.lua:8 -- unknown provides label '{value}', check DAW interface registry

Expected output:
init.lua:8 -- unknown provides label 'klo-papier', check DAW interface registry

Approach

Extend core/reporter.lua to substitute {value} from metrics.matches[].value
when present in the rule message template.

Acceptance criteria

  • {value} substituted in message when metrics.matches[].value exists
  • existing {file}, {line}, {count} substitution unaffected
## Goal The reporter currently only substitutes {file}, {line}, and {count} in rule messages. Primitives like listvalues produce per-value findings that need {value} substituted to show the offending value in the output. ## Example Current output: init.lua:8 -- unknown provides label '{value}', check DAW interface registry Expected output: init.lua:8 -- unknown provides label 'klo-papier', check DAW interface registry ## Approach Extend core/reporter.lua to substitute {value} from metrics.matches[].value when present in the rule message template. ## Acceptance criteria - [ ] {value} substituted in message when metrics.matches[].value exists - [ ] existing {file}, {line}, {count} substitution unaffected
michael added this to the Basic Version milestone 2026-05-30 16:04:44 +02:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
DAW/fragjan#85
No description provided.