Problem
Both bregctl check --format json findings and bregctl explain output identify configuration by structural path, for example entities[2].fields[5].constraints[0]. Neither says which file the construct came from, nor where in that file it sits.
For a single-file project a human can resolve this by reading. For a project assembled from several files, or one that a tool wants to link back to source, the structural path is not enough. Every consumer has to re-parse the project files itself and re-implement the mapping from structural path to file position, which means re-implementing assumptions about how the loader merges files.
Request
Either of:
- Source provenance inline: add
file and range (start and end line/column) next to path in explain output and in check findings.
- A separate map:
bregctl explain locations --format json returning structuralPath -> { file, range } for every addressable construct.
Option 2 is cheaper to add without disturbing existing payload shapes, and it lets consumers opt in.
Provenance should also distinguish authored configuration from values that came from a module or from an engine default, since "this field is not in your file because the engine supplied it" is a different answer from "this is at line 40".
Why it matters
Any tool that shows a project's configuration and wants to let a reader jump to where a rule is written needs this. Without it, the tool is guessing.
Problem
Both
bregctl check --format jsonfindings andbregctl explainoutput identify configuration by structural path, for exampleentities[2].fields[5].constraints[0]. Neither says which file the construct came from, nor where in that file it sits.For a single-file project a human can resolve this by reading. For a project assembled from several files, or one that a tool wants to link back to source, the structural path is not enough. Every consumer has to re-parse the project files itself and re-implement the mapping from structural path to file position, which means re-implementing assumptions about how the loader merges files.
Request
Either of:
fileandrange(start and end line/column) next topathin explain output and in check findings.bregctl explain locations --format jsonreturningstructuralPath -> { file, range }for every addressable construct.Option 2 is cheaper to add without disturbing existing payload shapes, and it lets consumers opt in.
Provenance should also distinguish authored configuration from values that came from a module or from an engine default, since "this field is not in your file because the engine supplied it" is a different answer from "this is at line 40".
Why it matters
Any tool that shows a project's configuration and wants to let a reader jump to where a rule is written needs this. Without it, the tool is guessing.