Plugins can't generate hcl.Ranges for errors that they emit: we're only sending the cty.Value from the fabric, and it doesn't include source code location information.
However plugins should be able to add specs to their diagnostics, which main fabric could turn into error ranges using hcldec.SourceRange.
Alternatively plugins may send a traversal path for the erroneous item:
Plugins can't generate
hcl.Range
s for errors that they emit: we're only sending thecty.Value
from thefabric
, and it doesn't include source code location information.However plugins should be able to add
spec
s to their diagnostics, which main fabric could turn into error ranges using hcldec.SourceRange.Alternatively plugins may send a traversal path for the erroneous item:
Path would look like []{"expr", "key", 0, "key_inner"}