mirror of
https://github.com/opentofu/opentofu.git
synced 2024-12-30 10:47:14 -06:00
a851566c56
Most of the time we're converting from HCL diagnostics to tfdiags as we expose diagnostics directly from HCL, but occasionally we need to to the reverse. For example, our configs package uses hcl.Diagnostics by convention because it's primarily working with HCL, but sometimes it interacts with functions elsewhere (like in the "addrs" package) that return tfdiags.Diagnostics, where they need to be adapted to return in an HCL shape. This should be used with some care because, similar to Diagnostics.ForRPC, it forces immediate flattening of all of the diagnostics to a single type and so can potentially lose internal tracking information that appears in other tfdiags.Diagnostic information, such as the additional metadata tracked in the ConsolidateWarnings result to allow later appending to existing groups. |
||
---|---|---|
.. | ||
config_traversals.go | ||
consolidate_warnings_test.go | ||
consolidate_warnings.go | ||
contextual_test.go | ||
contextual.go | ||
diagnostic_base.go | ||
diagnostic.go | ||
diagnostics_test.go | ||
diagnostics.go | ||
doc.go | ||
error.go | ||
hcl_test.go | ||
hcl.go | ||
rpc_friendly_test.go | ||
rpc_friendly.go | ||
severity_string.go | ||
simple_warning.go | ||
source_range.go | ||
sourceless.go |