core: Have WritePlan be explicit that it's non-functional right now

This is temporarily broken until we implement the new plan file format,
since terraform.Plan is no longer serializable with gob. Rather than have
an error that seems like it needs immediate fixing, we'll be explicit
about it in the error message and focus our efforts on other test failures
for now, and return to implement the new file format later.
This commit is contained in:
Martin Atkins 2018-05-29 16:37:32 -07:00
parent 798adf3ce6
commit 11bd07abb2
1 changed files with 2 additions and 0 deletions

View File

@ -242,6 +242,8 @@ func ReadPlan(src io.Reader) (*Plan, error) {
// WritePlan writes a plan somewhere in a binary format.
func WritePlan(d *Plan, dst io.Writer) error {
return fmt.Errorf("plan serialization is temporarily disabled, pending implementation of the new file format")
// Write the magic bytes so we can determine the file format later
n, err := dst.Write([]byte(planFormatMagic))
if err != nil {