mirror of
https://github.com/opentofu/opentofu.git
synced 2024-12-25 16:31:10 -06:00
1ad97f6be8
Remove the Input flag threaded through the input graph creation process to prevent interpolation failures on module variables. Use an EvalOpFilter instead to inset the correct EvalNode during walkInput. Remove the EvalTryInterpolate type, and use the same ContinueOnErr flag as the output node for consistency and to try and keep the number possible eval node types down.
28 lines
804 B
Go
28 lines
804 B
Go
package terraform
|
|
|
|
import (
|
|
"github.com/hashicorp/terraform/dag"
|
|
)
|
|
|
|
// InputGraphBuilder creates the graph for the input operation.
|
|
//
|
|
// Unlike other graph builders, this is a function since it currently modifies
|
|
// and is based on the PlanGraphBuilder. The PlanGraphBuilder passed in will be
|
|
// modified and should not be used for any other operations.
|
|
func InputGraphBuilder(p *PlanGraphBuilder) GraphBuilder {
|
|
// We're going to customize the concrete functions
|
|
p.CustomConcrete = true
|
|
|
|
// Set the provider to the normal provider. This will ask for input.
|
|
p.ConcreteProvider = func(a *NodeAbstractProvider) dag.Vertex {
|
|
return &NodeApplyableProvider{
|
|
NodeAbstractProvider: a,
|
|
}
|
|
}
|
|
|
|
// We purposely don't set any more concrete fields since the remainder
|
|
// should be no-ops.
|
|
|
|
return p
|
|
}
|