backend/local: Remove unused DisablePlanFileStateLineageChecks flag
Now that show command has been refactored to remove its dependence on a local backend and local run, this flag is no longer needed to fix #30195.
This commit is contained in:
parent
fea8f6cfa2
commit
64e1241ae3
|
@ -275,13 +275,6 @@ type Operation struct {
|
||||||
// the variables set in the plan are used instead, and they must be valid.
|
// the variables set in the plan are used instead, and they must be valid.
|
||||||
AllowUnsetVariables bool
|
AllowUnsetVariables bool
|
||||||
|
|
||||||
// When loading a plan file for a read-only operation, we may want to
|
|
||||||
// disable the state lineage checks which are only relevant for operations
|
|
||||||
// which can modify state. An example where this is important is showing
|
|
||||||
// a plan which was prepared against a non-default state file, because the
|
|
||||||
// lineage checks are always against the default state.
|
|
||||||
DisablePlanFileStateLineageChecks bool
|
|
||||||
|
|
||||||
// View implements the logic for all UI interactions.
|
// View implements the logic for all UI interactions.
|
||||||
View views.Operation
|
View views.Operation
|
||||||
|
|
||||||
|
|
|
@ -284,7 +284,7 @@ func (b *Local) localRunForPlanFile(op *backend.Operation, pf *planfile.Reader,
|
||||||
))
|
))
|
||||||
return nil, snap, diags
|
return nil, snap, diags
|
||||||
}
|
}
|
||||||
if !op.DisablePlanFileStateLineageChecks && currentStateMeta != nil {
|
if currentStateMeta != nil {
|
||||||
// If the caller sets this, we require that the stored prior state
|
// If the caller sets this, we require that the stored prior state
|
||||||
// has the same metadata, which is an extra safety check that nothing
|
// has the same metadata, which is an extra safety check that nothing
|
||||||
// has changed since the plan was created. (All of the "real-world"
|
// has changed since the plan was created. (All of the "real-world"
|
||||||
|
|
Loading…
Reference in New Issue